Hi,
Im rendering my scene in a controls by setting the HWND of the control in the SExposedVideoData.
Code: Select all
irr::video::SExposedVideoData data(m_hwnd);
m_pVideoDriver->beginScene(true, true, 0, data);
The control is placed in a dockable panel, docking and undocking the panel somehow changes the HWND of the control.
In my camera i use the relative position for some calculations.
Code: Select all
m_cursorStartPos = m_pCursorControl->getRelativePosition();
m_pCursorControl being a irr::gui::ICursorControl* uses the HWND which is set while creating the device. But since this HWND has changed the value returned by the code shown above is invalid. The scene is rendered as it should, also the key input is handled correctly, however the cursor movements remain an issue as they use the irr::gui::ICursorControl* which uses the invalid HWND.
Is there any way to change the HWND which was set in the constructor of the device and thus also updating the ICursorControl?
Thanks in advance