diff options
Diffstat (limited to 'Samples/CommonSrc/Render/Render_GL_Win32_Device.h')
-rw-r--r-- | Samples/CommonSrc/Render/Render_GL_Win32_Device.h | 24 |
1 files changed, 17 insertions, 7 deletions
diff --git a/Samples/CommonSrc/Render/Render_GL_Win32_Device.h b/Samples/CommonSrc/Render/Render_GL_Win32_Device.h index f63b1d0..de81a80 100644 --- a/Samples/CommonSrc/Render/Render_GL_Win32_Device.h +++ b/Samples/CommonSrc/Render/Render_GL_Win32_Device.h @@ -3,7 +3,7 @@ Filename : Render_GL_Win32 Device.h Content : Win32 OpenGL Device implementation header Created : September 10, 2012 -Authors : Andrew Reisse, Michael Antonov +Authors : Andrew Reisse, Michael Antonov, David Borel Copyright : Copyright 2012 Oculus VR, Inc. All Rights reserved. @@ -38,19 +38,29 @@ namespace OVR { namespace Render { namespace GL { namespace Win32 { // Win32-Specific GL Render Device, used to create OpenGL under Windows. class RenderDevice : public GL::RenderDevice { - HWND Window; - HGLRC WglContext; - HDC GdiDc; + friend BOOL CALLBACK MonitorEnumFunc(HMONITOR hMonitor, HDC, LPRECT, LPARAM dwData); + + HWND Window; + HGLRC WglContext; + HDC GdiDc; + Recti PreFullscreen; + Recti FSDesktop; + HMONITOR HMonitor; public: - RenderDevice(const Render::RendererParams& p, HWND win, HDC dc, HGLRC gl) - : GL::RenderDevice(p), Window(win), WglContext(gl), GdiDc(dc) { OVR_UNUSED(p); } + RenderDevice(const Render::RendererParams& p, HWND win, HDC dc, HGLRC gl); + virtual ~RenderDevice() { Shutdown(); } // Implement static initializer function to create this class. static Render::RenderDevice* CreateDevice(const RendererParams& rp, void* oswnd); + + virtual ovrRenderAPIConfig Get_ovrRenderAPIConfig() const; virtual void Shutdown(); - virtual void Present(); + virtual void Present(bool withVsync); + bool SetParams(const RendererParams& newParams); + + virtual bool SetFullscreen(DisplayMode fullscreen); }; |