[gst-devel] Python gst without GTK
Jens Gottstein
Jens.Gottstein at tu-bs.de
Wed Nov 17 21:19:01 CET 2010
Hi,
I am trying to write a command line player using gstreamer in python
In the example below, the on_message() is never called?
Can anybody tell me what I did wrong?
#!/usr/bin/python
import pygst
pygst.require("0.10")
import gst
def on_message(self, bus, message):
print "on_message"
player = gst.element_factory_make("playbin2", "player")
bus = player.get_bus()
bus.add_signal_watch()
bus.connect("message", on_message)
player.set_property("uri", "file:///usr/share/sounds/KDE_Error_3.ogg")
player.set_state(gst.STATE_PLAYING)
raw_input("anykey")
I am using debian, GStreamer Python bindings 0.10.12 "A Wild Finish"
Thanks a lot
More information about the gstreamer-devel
mailing list