Steppable 0.0.1
A CAS project written from scratch in C++
Loading...
Searching...
No Matches
glfw3native.h
1/*************************************************************************
2 * GLFW 3.2 - www.glfw.org
3 * A library for OpenGL, window and input
4 *------------------------------------------------------------------------
5 * Copyright (c) 2002-2006 Marcus Geelnard
6 * Copyright (c) 2006-2010 Camilla Berglund <elmindreda@elmindreda.org>
7 *
8 * This software is provided 'as-is', without any express or implied
9 * warranty. In no event will the authors be held liable for any damages
10 * arising from the use of this software.
11 *
12 * Permission is granted to anyone to use this software for any purpose,
13 * including commercial applications, and to alter it and redistribute it
14 * freely, subject to the following restrictions:
15 *
16 * 1. The origin of this software must not be misrepresented; you must not
17 * claim that you wrote the original software. If you use this software
18 * in a product, an acknowledgment in the product documentation would
19 * be appreciated but is not required.
20 *
21 * 2. Altered source versions must be plainly marked as such, and must not
22 * be misrepresented as being the original software.
23 *
24 * 3. This notice may not be removed or altered from any source
25 * distribution.
26 *
27 *************************************************************************/
28
29#ifndef _glfw3_native_h_
30#define _glfw3_native_h_
31
32#ifdef __cplusplus
33extern "C" {
34#endif
35
36
37/*************************************************************************
38 * Doxygen documentation
39 *************************************************************************/
40
77
78
79/*************************************************************************
80 * System headers and types
81 *************************************************************************/
82
83#if defined(GLFW_EXPOSE_NATIVE_WIN32)
84 // This is a workaround for the fact that glfw3.h needs to export APIENTRY (for
85 // example to allow applications to correctly declare a GL_ARB_debug_output
86 // callback) but windows.h assumes no one will define APIENTRY before it does
87 #undef APIENTRY
88 #include <windows.h>
89#elif defined(GLFW_EXPOSE_NATIVE_COCOA)
90 #include <ApplicationServices/ApplicationServices.h>
91 #if defined(__OBJC__)
92 #import <Cocoa/Cocoa.h>
93 #else
94 typedef void* id;
95 #endif
96#elif defined(GLFW_EXPOSE_NATIVE_X11)
97 #include <X11/Xlib.h>
98 #include <X11/extensions/Xrandr.h>
99#elif defined(GLFW_EXPOSE_NATIVE_WAYLAND)
100 #include <wayland-client.h>
101#elif defined(GLFW_EXPOSE_NATIVE_MIR)
102 #include <mir_toolkit/mir_client_library.h>
103#endif
104
105#if defined(GLFW_EXPOSE_NATIVE_WGL)
106 /* WGL is declared by windows.h */
107#endif
108#if defined(GLFW_EXPOSE_NATIVE_NSGL)
109 /* NSGL is declared by Cocoa.h */
110#endif
111#if defined(GLFW_EXPOSE_NATIVE_GLX)
112 #include <GL/glx.h>
113#endif
114#if defined(GLFW_EXPOSE_NATIVE_EGL)
115 #include <EGL/egl.h>
116#endif
117
118
119/*************************************************************************
120 * Functions
121 *************************************************************************/
122
123#if defined(GLFW_EXPOSE_NATIVE_WIN32)
137GLFWAPI const char* glfwGetWin32Adapter(GLFWmonitor* monitor);
138
152GLFWAPI const char* glfwGetWin32Monitor(GLFWmonitor* monitor);
153
166GLFWAPI HWND glfwGetWin32Window(GLFWwindow* window);
167#endif
168
169#if defined(GLFW_EXPOSE_NATIVE_WGL)
182GLFWAPI HGLRC glfwGetWGLContext(GLFWwindow* window);
183#endif
184
185#if defined(GLFW_EXPOSE_NATIVE_COCOA)
198GLFWAPI CGDirectDisplayID glfwGetCocoaMonitor(GLFWmonitor* monitor);
199
212GLFWAPI id glfwGetCocoaWindow(GLFWwindow* window);
213#endif
214
215#if defined(GLFW_EXPOSE_NATIVE_NSGL)
228GLFWAPI id glfwGetNSGLContext(GLFWwindow* window);
229#endif
230
231#if defined(GLFW_EXPOSE_NATIVE_X11)
244GLFWAPI Display* glfwGetX11Display(void);
245
258GLFWAPI RRCrtc glfwGetX11Adapter(GLFWmonitor* monitor);
259
272GLFWAPI RROutput glfwGetX11Monitor(GLFWmonitor* monitor);
273
286GLFWAPI Window glfwGetX11Window(GLFWwindow* window);
287#endif
288
289#if defined(GLFW_EXPOSE_NATIVE_GLX)
302GLFWAPI GLXContext glfwGetGLXContext(GLFWwindow* window);
303
316GLFWAPI GLXWindow glfwGetGLXWindow(GLFWwindow* window);
317#endif
318
319#if defined(GLFW_EXPOSE_NATIVE_WAYLAND)
332GLFWAPI struct wl_display* glfwGetWaylandDisplay(void);
333
346GLFWAPI struct wl_output* glfwGetWaylandMonitor(GLFWmonitor* monitor);
347
360GLFWAPI struct wl_surface* glfwGetWaylandWindow(GLFWwindow* window);
361#endif
362
363#if defined(GLFW_EXPOSE_NATIVE_MIR)
376GLFWAPI MirConnection* glfwGetMirDisplay(void);
377
390GLFWAPI int glfwGetMirMonitor(GLFWmonitor* monitor);
391
404GLFWAPI MirSurface* glfwGetMirWindow(GLFWwindow* window);
405#endif
406
407#if defined(GLFW_EXPOSE_NATIVE_EGL)
420GLFWAPI EGLDisplay glfwGetEGLDisplay(void);
421
434GLFWAPI EGLContext glfwGetEGLContext(GLFWwindow* window);
435
448GLFWAPI EGLSurface glfwGetEGLSurface(GLFWwindow* window);
449#endif
450
451#ifdef __cplusplus
452}
453#endif
454
455#endif /* _glfw3_native_h_ */
456
struct GLFWmonitor GLFWmonitor
Opaque monitor object.
Definition glfw3.h:770
struct GLFWwindow GLFWwindow
Opaque window object.
Definition glfw3.h:782
Untitled