[totem/wip/hadess/more-blacklist] gallery: Use new totem_gst_disable_display_decoders() helper



commit c2539ead78fe2862cd4eb2e4ee3853e58af1963e
Author: Bastien Nocera <hadess hadess net>
Date:   Mon Jan 14 20:05:16 2019 +0100

    gallery: Use new totem_gst_disable_display_decoders() helper

 src/totem-gallery-thumbnailer.c | 28 +---------------------------
 1 file changed, 1 insertion(+), 27 deletions(-)
---
diff --git a/src/totem-gallery-thumbnailer.c b/src/totem-gallery-thumbnailer.c
index 70d797d42..4f7585531 100644
--- a/src/totem-gallery-thumbnailer.c
+++ b/src/totem-gallery-thumbnailer.c
@@ -344,19 +344,6 @@ thumb_app_setup_play (ThumbApp *app)
 {
        GstElement *play;
        GstElement *audio_sink, *video_sink;
-       GstRegistry *registry;
-        const char *blacklisted_plugins[] = {
-          "vaapidecodebin",
-          "vaapidecode",
-          "vaapimpeg2dec",
-          "vaapih264dec",
-          "vaapivc1dec",
-          "vaapivp8dec",
-          "vaapivp9dec",
-          "vaapih265dec",
-          "bmcdec"
-        };
-        guint i;
 
        play = gst_element_factory_make ("playbin", "play");
        audio_sink = gst_element_factory_make ("fakesink", "audio-fake-sink");
@@ -371,20 +358,7 @@ thumb_app_setup_play (ThumbApp *app)
 
        app->play = play;
 
-       /* Disable the vaapi plugin as it will not work with the
-        * fakesink we use:
-        * See: https://bugzilla.gnome.org/show_bug.cgi?id=700186 and
-        * https://bugzilla.gnome.org/show_bug.cgi?id=749605 */
-       registry = gst_registry_get ();
-
-       for (i = 0; i < G_N_ELEMENTS (blacklisted_plugins); i++) {
-               GstPluginFeature *feature =
-                       gst_registry_find_feature (registry,
-                                                  blacklisted_plugins[i],
-                                                  GST_TYPE_ELEMENT_FACTORY);
-               if (feature)
-                       gst_registry_remove_feature (registry, feature);
-       }
+       totem_gst_disable_display_decoders ();
 }
 
 static void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]