Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManuel Kaufmann <humitos@gmail.com>2012-10-02 19:48:37 (GMT)
committer Gonzalo Odiard <godiard@gmail.com>2012-10-10 16:24:37 (GMT)
commit1b481d1ac0943ef6c2b5ea084d37b9d7e961892c (patch)
treec2e72573ebbe382de4fcb8829396241d1ebdcedd
parent3ac69625c4ec6cca261f9925793b6657a37a0031 (diff)
Use 'playbin2' instead of 'playbin'
'playbin' is obsolete and not should be used. I was told in #gstreamer (irc.freenode.net) that 'playbin' is no longer supported, that has some bugs and shouldn't be used anymore. It should be changed by 'playbin2' I had to set some flags as well to keep showing the 'vis-plugin' with 'playbin2' player. Signed-off-by: Manuel Kaufmann <humitos@gmail.com>
-rw-r--r--jukeboxactivity.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/jukeboxactivity.py b/jukeboxactivity.py
index 11e1331..5c02d23 100644
--- a/jukeboxactivity.py
+++ b/jukeboxactivity.py
@@ -698,7 +698,13 @@ class GstPlayer(GObject.GObject):
self.playing = False
self.error = False
- self.player = gst.element_factory_make("playbin", "player")
+ self.player = gst.element_factory_make("playbin2", "player")
+
+ # Set the proper flags to render the vis-plugin
+ GST_PLAY_FLAG_VIS = 1 << 3
+ GST_PLAY_FLAG_TEXT = 1 << 2
+ self.player.props.flags |= GST_PLAY_FLAG_VIS
+ self.player.props.flags |= GST_PLAY_FLAG_TEXT
r = gst.registry_get_default()
l = [x for x in r.get_feature_list(gst.ElementFactory)