Add GLFW_CONTEXT_DEBUG window hint alias

From upstream: b420ca7404.
This commit is contained in:
Luflosi 2020-06-29 11:49:49 +02:00
parent ef0e610802
commit bd31c2b484
No known key found for this signature in database
GPG Key ID: 4E41E29EDCC345D0
5 changed files with 20 additions and 10 deletions

11
glfw/glfw3.h vendored
View File

@ -1056,10 +1056,15 @@ extern "C" {
#define GLFW_OPENGL_FORWARD_COMPAT 0x00022006 #define GLFW_OPENGL_FORWARD_COMPAT 0x00022006
/*! @brief Debug mode context hint and attribute. /*! @brief Debug mode context hint and attribute.
* *
* Debug mode context [hint](@ref GLFW_OPENGL_DEBUG_CONTEXT_hint) and * Debug mode context [hint](@ref GLFW_CONTEXT_DEBUG_hint) and
* [attribute](@ref GLFW_OPENGL_DEBUG_CONTEXT_attrib). * [attribute](@ref GLFW_CONTEXT_DEBUG_attrib).
*/ */
#define GLFW_OPENGL_DEBUG_CONTEXT 0x00022007 #define GLFW_CONTEXT_DEBUG 0x00022007
/*! @brief Legacy name for compatibility.
*
* This is an alias for compatibility with earlier versions.
*/
#define GLFW_OPENGL_DEBUG_CONTEXT GLFW_CONTEXT_DEBUG
/*! @brief OpenGL profile hint and attribute. /*! @brief OpenGL profile hint and attribute.
* *
* OpenGL profile [hint](@ref GLFW_OPENGL_PROFILE_hint) and * OpenGL profile [hint](@ref GLFW_OPENGL_PROFILE_hint) and

4
glfw/window.c vendored
View File

@ -440,7 +440,7 @@ GLFWAPI void glfwWindowHint(int hint, int value)
case GLFW_OPENGL_FORWARD_COMPAT: case GLFW_OPENGL_FORWARD_COMPAT:
_glfw.hints.context.forward = value ? true : false; _glfw.hints.context.forward = value ? true : false;
return; return;
case GLFW_OPENGL_DEBUG_CONTEXT: case GLFW_CONTEXT_DEBUG:
_glfw.hints.context.debug = value ? true : false; _glfw.hints.context.debug = value ? true : false;
return; return;
case GLFW_CONTEXT_NO_ERROR: case GLFW_CONTEXT_NO_ERROR:
@ -931,7 +931,7 @@ GLFWAPI int glfwGetWindowAttrib(GLFWwindow* handle, int attrib)
return window->context.robustness; return window->context.robustness;
case GLFW_OPENGL_FORWARD_COMPAT: case GLFW_OPENGL_FORWARD_COMPAT:
return window->context.forward; return window->context.forward;
case GLFW_OPENGL_DEBUG_CONTEXT: case GLFW_CONTEXT_DEBUG:
return window->context.debug; return window->context.debug;
case GLFW_OPENGL_PROFILE: case GLFW_OPENGL_PROFILE:
return window->context.profile; return window->context.profile;

View File

@ -275,7 +275,7 @@ GLFW_CONTEXT_VERSION_MINOR: int
GLFW_CONTEXT_REVISION: int GLFW_CONTEXT_REVISION: int
GLFW_CONTEXT_ROBUSTNESS: int GLFW_CONTEXT_ROBUSTNESS: int
GLFW_OPENGL_FORWARD_COMPAT: int GLFW_OPENGL_FORWARD_COMPAT: int
GLFW_OPENGL_DEBUG_CONTEXT: int GLFW_CONTEXT_DEBUG: int
GLFW_OPENGL_PROFILE: int GLFW_OPENGL_PROFILE: int
GLFW_OPENGL_API: int GLFW_OPENGL_API: int
GLFW_OPENGL_ES_API: int GLFW_OPENGL_ES_API: int

11
kitty/glfw-wrapper.h generated
View File

@ -794,10 +794,15 @@
#define GLFW_OPENGL_FORWARD_COMPAT 0x00022006 #define GLFW_OPENGL_FORWARD_COMPAT 0x00022006
/*! @brief Debug mode context hint and attribute. /*! @brief Debug mode context hint and attribute.
* *
* Debug mode context [hint](@ref GLFW_OPENGL_DEBUG_CONTEXT_hint) and * Debug mode context [hint](@ref GLFW_CONTEXT_DEBUG_hint) and
* [attribute](@ref GLFW_OPENGL_DEBUG_CONTEXT_attrib). * [attribute](@ref GLFW_CONTEXT_DEBUG_attrib).
*/ */
#define GLFW_OPENGL_DEBUG_CONTEXT 0x00022007 #define GLFW_CONTEXT_DEBUG 0x00022007
/*! @brief Legacy name for compatibility.
*
* This is an alias for compatibility with earlier versions.
*/
#define GLFW_OPENGL_DEBUG_CONTEXT GLFW_CONTEXT_DEBUG
/*! @brief OpenGL profile hint and attribute. /*! @brief OpenGL profile hint and attribute.
* *
* OpenGL profile [hint](@ref GLFW_OPENGL_PROFILE_hint) and * OpenGL profile [hint](@ref GLFW_OPENGL_PROFILE_hint) and

View File

@ -1532,7 +1532,7 @@ init_glfw(PyObject *m) {
ADDC(GLFW_CONTEXT_REVISION); ADDC(GLFW_CONTEXT_REVISION);
ADDC(GLFW_CONTEXT_ROBUSTNESS); ADDC(GLFW_CONTEXT_ROBUSTNESS);
ADDC(GLFW_OPENGL_FORWARD_COMPAT); ADDC(GLFW_OPENGL_FORWARD_COMPAT);
ADDC(GLFW_OPENGL_DEBUG_CONTEXT); ADDC(GLFW_CONTEXT_DEBUG);
ADDC(GLFW_OPENGL_PROFILE); ADDC(GLFW_OPENGL_PROFILE);
// --- // ---