wgl_context.h
Go to the documentation of this file.
00001 //========================================================================
00002 // GLFW 3.1 WGL - www.glfw.org
00003 //------------------------------------------------------------------------
00004 // Copyright (c) 2002-2006 Marcus Geelnard
00005 // Copyright (c) 2006-2010 Camilla Berglund <elmindreda@elmindreda.org>
00006 //
00007 // This software is provided 'as-is', without any express or implied
00008 // warranty. In no event will the authors be held liable for any damages
00009 // arising from the use of this software.
00010 //
00011 // Permission is granted to anyone to use this software for any purpose,
00012 // including commercial applications, and to alter it and redistribute it
00013 // freely, subject to the following restrictions:
00014 //
00015 // 1. The origin of this software must not be misrepresented; you must not
00016 //    claim that you wrote the original software. If you use this software
00017 //    in a product, an acknowledgment in the product documentation would
00018 //    be appreciated but is not required.
00019 //
00020 // 2. Altered source versions must be plainly marked as such, and must not
00021 //    be misrepresented as being the original software.
00022 //
00023 // 3. This notice may not be removed or altered from any source
00024 //    distribution.
00025 //
00026 //========================================================================
00027 
00028 #ifndef _glfw3_wgl_context_h_
00029 #define _glfw3_wgl_context_h_
00030 
00031 // This path may need to be changed if you build GLFW using your own setup
00032 // We ship and use our own copy of wglext.h since GLFW uses fairly new
00033 // extensions and not all operating systems come with an up-to-date version
00034 #include "../deps/GL/wglext.h"
00035 
00036 // opengl32.dll function pointer typedefs
00037 typedef HGLRC (WINAPI * WGLCREATECONTEXT_T)(HDC);
00038 typedef BOOL (WINAPI * WGLDELETECONTEXT_T)(HGLRC);
00039 typedef PROC (WINAPI * WGLGETPROCADDRESS_T)(LPCSTR);
00040 typedef BOOL (WINAPI * WGLMAKECURRENT_T)(HDC,HGLRC);
00041 typedef BOOL (WINAPI * WGLSHARELISTS_T)(HGLRC,HGLRC);
00042 #define _glfw_wglCreateContext _glfw.wgl.opengl32.CreateContext
00043 #define _glfw_wglDeleteContext _glfw.wgl.opengl32.DeleteContext
00044 #define _glfw_wglGetProcAddress _glfw.wgl.opengl32.GetProcAddress
00045 #define _glfw_wglMakeCurrent _glfw.wgl.opengl32.MakeCurrent
00046 #define _glfw_wglShareLists _glfw.wgl.opengl32.ShareLists
00047 
00048 #define _GLFW_PLATFORM_FBCONFIG                 int             wgl
00049 #define _GLFW_PLATFORM_CONTEXT_STATE            _GLFWcontextWGL wgl
00050 #define _GLFW_PLATFORM_LIBRARY_CONTEXT_STATE    _GLFWlibraryWGL wgl
00051 
00052 
00053 // WGL-specific per-context data
00054 //
00055 typedef struct _GLFWcontextWGL
00056 {
00057     HDC       dc;              // Private GDI device context
00058     HGLRC     context;         // Permanent rendering context
00059     int       interval;
00060 
00061     // WGL extensions (context specific)
00062     PFNWGLSWAPINTERVALEXTPROC           SwapIntervalEXT;
00063     PFNWGLGETPIXELFORMATATTRIBIVARBPROC GetPixelFormatAttribivARB;
00064     PFNWGLGETEXTENSIONSSTRINGEXTPROC    GetExtensionsStringEXT;
00065     PFNWGLGETEXTENSIONSSTRINGARBPROC    GetExtensionsStringARB;
00066     PFNWGLCREATECONTEXTATTRIBSARBPROC   CreateContextAttribsARB;
00067     GLboolean                           EXT_swap_control;
00068     GLboolean                           ARB_multisample;
00069     GLboolean                           ARB_framebuffer_sRGB;
00070     GLboolean                           EXT_framebuffer_sRGB;
00071     GLboolean                           ARB_pixel_format;
00072     GLboolean                           ARB_create_context;
00073     GLboolean                           ARB_create_context_profile;
00074     GLboolean                           EXT_create_context_es2_profile;
00075     GLboolean                           ARB_create_context_robustness;
00076     GLboolean                           ARB_context_flush_control;
00077 
00078 } _GLFWcontextWGL;
00079 
00080 
00081 // WGL-specific global data
00082 //
00083 typedef struct _GLFWlibraryWGL
00084 {
00085     struct {
00086         HINSTANCE           instance;
00087         WGLCREATECONTEXT_T  CreateContext;
00088         WGLDELETECONTEXT_T  DeleteContext;
00089         WGLGETPROCADDRESS_T GetProcAddress;
00090         WGLMAKECURRENT_T    MakeCurrent;
00091         WGLSHARELISTS_T     ShareLists;
00092     } opengl32;
00093 
00094 } _GLFWlibraryWGL;
00095 
00096 
00097 int _glfwInitContextAPI(void);
00098 void _glfwTerminateContextAPI(void);
00099 int _glfwCreateContext(_GLFWwindow* window,
00100                        const _GLFWctxconfig* ctxconfig,
00101                        const _GLFWfbconfig* fbconfig);
00102 void _glfwDestroyContext(_GLFWwindow* window);
00103 int _glfwAnalyzeContext(const _GLFWwindow* window,
00104                         const _GLFWctxconfig* ctxconfig,
00105                         const _GLFWfbconfig* fbconfig);
00106 
00107 #endif // _glfw3_wgl_context_h_


librealsense
Author(s): Sergey Dorodnicov , Mark Horn , Reagan Lopez
autogenerated on Tue Jun 25 2019 19:54:39