void TJS_INTF_METHOD IrrlichtDrawDevice::SetDestRectangle(const tTVPRect &dest) { destRect.setLeft(dest.left); destRect.setTop(dest.top); destRect.setWidth((destWidth = dest.get_width())); destRect.setHeight((destHeight = dest.get_height())); if (device) { IVideoDriver *driver = device->getVideoDriver(); if (driver) { tjs_int w, h; if (zoomMode) { w = width; h = height; } else { w = destWidth; h = destHeight; } if (screenWidth != w || screenHeight != h) { screenWidth = w; screenHeight = h; screenRect = rect<s32>(0,0,screenWidth,screenHeight); driver->OnResize(dimension2d<s32>(w, h)); } } } }
void IrrlichtSimpleDevice::_setSize() { if (useRender) { TVPThrowExceptionMessage(L"can't change width/height when render mode"); } if (device) { IVideoDriver *driver = device->getVideoDriver(); if (driver) { driver->OnResize(dimension2d<s32>(width, height)); } } }