mirror of
https://github.com/glfw/glfw.git
synced 2026-09-22 08:50:15 +00:00
Merge branch 'master' of github.com:elmindreda/glfw
This commit is contained in:
+24
-2
@@ -113,7 +113,7 @@ static GLXContext createLegacyContext(_GLFWwindow* window,
|
||||
// Initialize GLX
|
||||
//========================================================================
|
||||
|
||||
int _glfwInitOpenGL(void)
|
||||
int _glfwInitContextAPI(void)
|
||||
{
|
||||
#ifdef _GLFW_DLOPEN_LIBGL
|
||||
int i;
|
||||
@@ -237,7 +237,7 @@ int _glfwInitOpenGL(void)
|
||||
// Terminate GLX
|
||||
//========================================================================
|
||||
|
||||
void _glfwTerminateOpenGL(void)
|
||||
void _glfwTerminateContextAPI(void)
|
||||
{
|
||||
// Unload libGL.so if necessary
|
||||
#ifdef _GLFW_DLOPEN_LIBGL
|
||||
@@ -633,3 +633,25 @@ GLFWglproc _glfwPlatformGetProcAddress(const char* procname)
|
||||
return _glfw_glXGetProcAddress((const GLubyte*) procname);
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
////// GLFW native API //////
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
//========================================================================
|
||||
// Return the GLX context of the specified window
|
||||
//========================================================================
|
||||
|
||||
GLFWAPI GLXContext glfwGetGLXContext(GLFWwindow* handle)
|
||||
{
|
||||
_GLFWwindow* window = (_GLFWwindow*) handle;
|
||||
|
||||
if (!_glfwInitialized)
|
||||
{
|
||||
_glfwInputError(GLFW_NOT_INITIALIZED, NULL);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
return window->glx.context;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user