4

I need to write a program on my Raspberry Pi to get a video and audio stream with Gstreamer from network and play them.(I have two stream. one for video and one for audio) and i need a custom GUI. I followed the below link :

http://www.jonobacon.org/2006/08/28/getting-started-with-gstreamer-with-python/

It used PyGtk and I want to switch to PyGObject. my question is : does PyObject support Gstreamer as well as PyGTK? or I should stuck to PyGTK? Or do you have a better solution to do that on Raspberry Pi

user3397145
  • 787
  • 1
  • 5
  • 16
  • I don't want to disappoint you but I think writing a video player is not a good idea, **specially** on Raspberry Pi. You want to know why? Try popular desktop video players like **vlc** or **mplayer** with HD videos. They are all laggy (except for Kodi / XBMC) because Pi has a low CPU and high GPU. That's why Kodi / XBMC is the only real good option as a video player on Pi because it uses GPU to handle codecs... – saeedgnu Jul 11 '15 at 12:35

1 Answers1

3

Considering the age of the article you linked, you might already know that there are newer versions of the libraries around. PyGtk and PyGst don't provide bindings for these.

Python GObject Introspection supports the Gkt-3.0 and Gst-1.0 versions. So you're safe using PyGObject for your program.

There's a quite good documentation on lazka.github.io/pgi-docs/ covering a lot more bindings as well.

Besides if you're going to build an audio/video player have a look at the playbin element. It's a complete pipeline supporting an audio-, a video- and a text-sink at once.

tynn
  • 38,113
  • 8
  • 108
  • 143
  • I am beginner. I think i don't understand. can you explain more please? – user3397145 Jun 16 '15 at 03:23
  • What exactly don't you understand? What should be explained more? – tynn Jun 16 '15 at 05:16
  • sorry for late reply(i was busy with university exams)I'm not sure what `playbin` is. – user3397145 Jun 28 '15 at 15:02
  • I've added the link to playbin. I have [a question using it](http://stackoverflow.com/q/30764939/3385212) here on stackoverflow as well. Please accept the answer if it answered your question "PyGObject or PyGtk". If there's any other unclarity, let me know. – tynn Jun 30 '15 at 12:15