|
@@ -19,6 +19,7 @@
|
|
|
|
|
|
// CHANGELOG
|
|
|
// (minor and older changes stripped away, please see git history for details)
|
|
|
+// 2023-06-20: OpenGL: Fixed erroneous use glGetIntegerv(GL_CONTEXT_PROFILE_MASK) on contexts lower than 3.2. (#6539, #6333)
|
|
|
// 2023-05-09: OpenGL: Support for glBindSampler() backup/restore on ES3. (#6375)
|
|
|
// 2023-04-18: OpenGL: Restore front and back polygon mode separately when supported by context. (#6333)
|
|
|
// 2023-03-23: OpenGL: Properly restoring "no shader program bound" if it was the case prior to running the rendering function. (#6267, #6220, #6224)
|
|
@@ -301,7 +302,8 @@ bool ImGui_ImplOpenGL3_Init(const char* glsl_version)
|
|
|
}
|
|
|
bd->GlVersion = (GLuint)(major * 100 + minor * 10);
|
|
|
#if defined(GL_CONTEXT_PROFILE_MASK)
|
|
|
- glGetIntegerv(GL_CONTEXT_PROFILE_MASK, &bd->GlProfileMask);
|
|
|
+ if (bd->GlVersion >= 320)
|
|
|
+ glGetIntegerv(GL_CONTEXT_PROFILE_MASK, &bd->GlProfileMask);
|
|
|
bd->GlProfileIsCompat = (bd->GlProfileMask & GL_CONTEXT_COMPATIBILITY_PROFILE_BIT) != 0;
|
|
|
#endif
|
|
|
|