SExposedVideoData

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
Seven
Posts: 1030
Joined: Mon Nov 14, 2005 2:03 pm

SExposedVideoData

Post by Seven »

using MFC and irrlicht 1.8, in the MFC view class I use this for rendering.
when using directx9 driver all is fine and each splitter pane renders as expected but when using the opengl driver, the entire screen is rendered to instead of the splitter windows hWnd.

m_hWnd is the splitter view's safe hwnd;

Code: Select all

 
    SExposedVideoData video;
    switch (pDoc->getApplication()->getDriver()->getDriverType())
    {
    case EDT_DIRECT3D9:
        video.D3D9.HWnd = m_hWnd;
        pDoc->getApplication()->getDriver()->beginScene(true, true, SColor(20, 20, 20, 20), video);
        pDoc->getApplication()->getActiveLevel()->render();
        pDoc->getApplication()->getDriver()->endScene();
        break;
    case EDT_OPENGL:
        video.OpenGLWin32.HWnd = m_hWnd;
        pDoc->getApplication()->getDriver()->beginScene(true, true, SColor(20, 20, 20, 20), video);
        pDoc->getApplication()->getActiveLevel()->render();
        pDoc->getApplication()->getDriver()->endScene();
        break;
    }
 
is something different needed with opengl than directx?
CuteAlien
Admin
Posts: 9651
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: SExposedVideoData

Post by CuteAlien »

You mean it renders fullscreen? Or full-window?
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Seven
Posts: 1030
Joined: Mon Nov 14, 2005 2:03 pm

Re: SExposedVideoData

Post by Seven »

it renders full window but not full screen.
CuteAlien
Admin
Posts: 9651
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: SExposedVideoData

Post by CuteAlien »

I just checked example 14 and it does do some additional stuff for OpenGL. Maybe copy the part it does in the "if (driverType==video::EDT_OPENGL)" section.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Post Reply