Page 1 of 1

return irrlicht window handle

Posted: Fri Nov 12, 2010 5:46 am
by codydbgt
I was wondering how I would get the irrlicht device window handle.

This is all I could find and it gives me an error but mabe I'm missing something

http://irrlicht.sourceforge.net/phpBB2/ ... d008f210ae

so i tried this

Code: Select all

 reinterpret_cast<HWND>(video::IVideoDriver::getExposedVideoData()->OpenGLWin32.HWnd)
well of course I got a compile error since i was trying to call a class and not a object I think :oops:

Posted: Fri Nov 12, 2010 7:48 am
by slavik262
Replace video::IVideoDriver:: with a pointer to the video driver and it will work a lot better. :D

Re: return irrlicht window handle

Posted: Fri Nov 12, 2010 8:24 am
by greenya
codydbgt wrote: so i tried this

Code: Select all

 reinterpret_cast<HWND>(video::IVideoDriver::getExposedVideoData()->OpenGLWin32.HWnd)
well of course I got a compile error since i was trying to call a class and not a object I think :oops:
To call getExposedVideoData() you need an instance of video::IVideoDriver; this instance can be received from device->getVideoDriver() call. And the device is a result of createDevice().

Re: return irrlicht window handle

Posted: Sat Jan 04, 2020 8:36 pm
by netpipe
what is the linux version ?