gl: use gst_gl_platform_from_string because we support gl shareList on all platforms
authorJulien Isorce <julien.isorce@collabora.co.uk>
Mon, 28 Apr 2014 14:15:20 +0000 (15:15 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Sat, 9 Dec 2017 19:31:38 +0000 (19:31 +0000)
ext/gl/gstgltestsrc.c
gst-libs/gst/gl/gstglfilter.c
gst-libs/gst/gl/gstglmixer.c

index 4fb30647ef8459cfae2db202f6c926b2e6081ee2..b7b2792a8e9e8a2c52fb82a008446754f254b9bb 100644 (file)
@@ -645,9 +645,7 @@ gst_gl_test_src_decide_allocation (GstBaseSrc * basesrc, GstQuery * query)
         GST_DEBUG ("got GL context handle 0x%p with type %s and apis %s",
             handle, type, apis);
 
-        if (g_strcmp0 (type, "glx") == 0)
-          platform = GST_GL_PLATFORM_GLX;
-
+        platform = gst_gl_platform_from_string (type);
         gl_apis = gst_gl_api_from_string (apis);
 
         if (gl_apis && platform)
index 3f900712f04ce5ef93e90dbacc14c8deb91a17dd..1775c46814fe976982d8375fbb18817707334b05 100644 (file)
@@ -929,9 +929,7 @@ gst_gl_filter_decide_allocation (GstBaseTransform * trans, GstQuery * query)
         GST_DEBUG ("got GL context handle 0x%p with type %s and apis %s",
             handle, type, apis);
 
-        if (g_strcmp0 (type, "glx") == 0)
-          platform = GST_GL_PLATFORM_GLX;
-
+        platform = gst_gl_platform_from_string (type);
         gl_apis = gst_gl_api_from_string (apis);
 
         if (gl_apis && platform)
index fbfbda8ebfa704a9924e0bf90acc4573a7b0aa56..238f4e1030dd426833335b5fe07bacb66225ac24 100644 (file)
@@ -1146,9 +1146,7 @@ gst_gl_mixer_decide_allocation (GstGLMixer * mix, GstQuery * query)
         GST_DEBUG ("got GL context handle 0x%p with type %s and apis %s",
             handle, type, apis);
 
-        if (g_strcmp0 (type, "glx") == 0)
-          platform = GST_GL_PLATFORM_GLX;
-
+        platform = gst_gl_platform_from_string (type);
         gl_apis = gst_gl_api_from_string (apis);
 
         if (gl_apis && platform)