Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

New media player plugin based on GStreamer framework

edited December 2013 in OpenSesame

Because I have never been really happy with the limitations of the VLC based media player plugin, I have been working on a similar plugin based on the GStreamer framework. This is a well-maintained cross-platform media playing framework that has earned its merits and has been used in a lot of applications.

Benefits of the Gst based plugin are:

  • Works in all backends (best in the hardware accelerated backends: psychopy and experiment).
  • Works on Windows, Linux and Mac.
    On OSX the plugin still has some quirks such as freezing of 1080p movies on slower systems, and sometimes failure to play audio streams of a certain format.

  • OpenSesame renders the frames itself (opposed to the VLC plugin, which just 'hijacks' the display window from OpenSesame and dumps its video output in there). This offers a much larger degree of control and even enables the possibility of drawing items on top of the video or playing multiple movies concurrently in future!

The current version is based on GStreamer 0.10, but I'm going to see if I can port it to version 1.0 in the near future.

You can find the plugin and installation instructions at The latest release version can be downloaded from

If you have a chance to try it out, please let me know of your experiences and provide feedback!


  • edited 4:41PM

    Hi Daniel,

    Great work! Indeed, it works really well. When I package the next 2.8.0 pre-release, I'll include the media_player_gst plug-in as well.

    Cheers and merry Christmas,

  • edited 4:41PM

    Great work! Indeed, it works really well. When I package the next 2.8.0 pre-release, I'll include the media_player_gst plug-in as well.

    When I wrote this, it slipped my mind that the software stack that is required for the media_player_gst is a bit too large to include by default. But if we manage to trim this down, we can include the media_player_gst by default.

  • edited 4:41PM

    No we need only a fraction of the plugins that are included with gstreamer. I'm certain we can trim it down quite a lot. I've started doing so, but with limited success up until now. Nevertheless I'll get there!

  • edited 4:41PM

    What's your limit on the file-size? I already managed to trim the whole framework down to 150 MB and that's just my first go. We can also sacrifice on some codecs, meaning that less file formats are supported, but if we were never going to use these in the first place why not?

  • edited 4:41PM

    I'm very new to OpenSesame and was hoping for some help. I installed the gst plugin, however, when I try to drag the icon into the experiment, the following message appears: "Failed to load plugin 'media_player_gst'. Error: cannot import name osexception". I'm using a mac. Any suggestions?

  • edited 4:41PM

    Hi Mike,

    The osexception class is only available in OpenSesame 2.8.0, i.e. the current development version. I added a small fix for backwards compatibility with earlier version of OpenSesame. To get this fix you should get the latest snapshot from my repository (Daniel is away the moment):

    The media_player_gst player has been tested mostly with OpenSesame 2.8.0 though, so there is a chance that you will run into more issues. But it's worth a shot to try the latest version from the repository linked to above.


  • edited 4:41PM

    Does anyone have feedback on how this plugin works for them and if the above problems have been solved? I would really like to know.

  • edited 4:41PM
    Failed to load plug-in 'media_player_gst'
    line: 61
    exception message: __init__() got an unexpected keyword argument 'builtins'
    exception type: TypeError
    Traceback (also in debug window):
      File "/usr/lib/pymodules/python2.7/libqtopensesame/", line 1350, in add_item
        self.experiment, None, self.experiment.item_prefix())
      File "/usr/lib/pymodules/python2.7/libopensesame/", line 295, in load_plugin
        item = item_class(item_name, experiment, string)
      File "/home/raid1/winklermax/plugins/media_player_gst/", line 923, in __init__
        qtautoplugin.__init__(self, __file__)
      File "/usr/lib/pymodules/python2.7/libqtopensesame/items/", line 30, in __init__
        qtplugin.__init__(self, plugin_file)
      File "/usr/lib/pymodules/python2.7/libqtopensesame/items/", line 62, in __init__
      File "/usr/lib/pymodules/python2.7/libqtopensesame/items/", line 47, in __init__
      File "/usr/lib/pymodules/python2.7/libqtopensesame/items/", line 102, in init_edit_widget
        syntax=c[u'syntax'], tooltip=c[u'tooltip'])
      File "/usr/lib/pymodules/python2.7/libqtopensesame/items/", line 362, in add_editor_control
      File "/usr/lib/pymodules/python2.7/QProgEdit/", line 109, in addTab
        handler=self.handler, focusOutHandler=self.focusOutHandler)
      File "/usr/lib/pymodules/python2.7/QProgEdit/", line 69, in __init__
        self.editor = QEditor(self, lang=lang)
      File "/usr/lib/pymodules/python2.7/QProgEdit/", line 50, in __init__
      File "/usr/lib/pymodules/python2.7/QProgEdit/", line 241, in setLang
      File "/usr/lib/pymodules/python2.7/QProgEdit/", line 289, in validate
        for l, s in validator(self.text()):
      File "/usr/lib/pymodules/python2.7/QProgEdit/validate/", line 61, in python
        for msg in Checker(c, builtins=_builtins).messages:
    TypeError: __init__() got an unexpected keyword argument 'builtins'

    This is all I get so far, just by inserting the module into my experiment.

  • edited 4:41PM

    This rather appears to be an error in QProgEdit to me. Are you running from source? If so, update that package by getting the latest version from and try again. Let me know if it works.

  • edited 4:41PM

    This is actually due to an outdated version of pyflakes, the module that is used by QProgEdit to validate Python code. See also:

    The solution would simply be to update pyflakes. At any rate, it's not due to the media_player_gst plug-in!

  • edited March 2014

    The error is gone. Thanks :)

    All fine!

  • edited December 2014

    I'm trying to get GStreamer to run and I can't even get to the stage of the plugin appearing in Open Sesame. I've followed the instructions on both OSX and Win7. With a default installation of the GStreamer framework and copying the plugin files to the /opensesame/plugins/media_player_gst directory ... is there something else I need to do? Thanks.

  • edited 4:41PM

    ah, finally got it to work! I think something was funky in my windows installation (running on boot camp) that made open sesame unable to detect the plugin... all better now!

  • floflo
    edited 4:41PM


    I am about a year late to the party, but...

    I need to play a video at the beginning of my experiment. The default video_player item doesn't seem to work for me (see my post here).

    I am building the experiment using OpenSesame 2.9.6 on Mac OS Yosemite but I will run the experiment on a tablet using the droid back-end. Will this media player plugin allow me to do that?


    • Florian
  • edited 4:41PM

    Hi Florian,
    Sadly no, there is no support for video playback on Android devices yet.

  • Hi Daniel,
    the link that reads " the GStreamer SDK website" in your original note of the plugin and installation instructions is a broken link. Could you please direct me to this site as I am trying to download!

  • Hi J,

    This here: is there website. There are also download links.

    Good luck,


Sign In or Register to comment.