mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-06-05 06:58:56 +00:00
glcontext: Fix unused variable warning by moving declaration where it is actually used
This commit is contained in:
parent
11485e32ab
commit
aea08e86a5
1 changed files with 2 additions and 3 deletions
|
@ -494,9 +494,6 @@ gst_gl_context_get_current_gl_api (guint * major, guint * minor)
|
||||||
|
|
||||||
goto next;
|
goto next;
|
||||||
} else {
|
} else {
|
||||||
#if GST_GL_HAVE_OPENGL
|
|
||||||
GLuint context_flags = 0;
|
|
||||||
#endif
|
|
||||||
sscanf (version, "%d.%d", &maj, &min);
|
sscanf (version, "%d.%d", &maj, &min);
|
||||||
|
|
||||||
if (maj <= 0 || min < 0)
|
if (maj <= 0 || min < 0)
|
||||||
|
@ -504,6 +501,8 @@ gst_gl_context_get_current_gl_api (guint * major, guint * minor)
|
||||||
|
|
||||||
#if GST_GL_HAVE_OPENGL
|
#if GST_GL_HAVE_OPENGL
|
||||||
if (GetIntegerv && (maj > 3 || (maj == 3 && min > 1))) {
|
if (GetIntegerv && (maj > 3 || (maj == 3 && min > 1))) {
|
||||||
|
GLuint context_flags = 0;
|
||||||
|
|
||||||
ret = GST_GL_API_NONE;
|
ret = GST_GL_API_NONE;
|
||||||
GetIntegerv (GL_CONTEXT_PROFILE_MASK, &context_flags);
|
GetIntegerv (GL_CONTEXT_PROFILE_MASK, &context_flags);
|
||||||
if (context_flags & GL_CONTEXT_CORE_PROFILE_BIT)
|
if (context_flags & GL_CONTEXT_CORE_PROFILE_BIT)
|
||||||
|
|
Loading…
Reference in a new issue