From fe32288e89651bf80b94cf5421daca431c7f45ca Mon Sep 17 00:00:00 2001 From: MaZderMind Date: Fri, 22 Aug 2014 17:32:19 +0200 Subject: add a sleep which fixes the startup issue --- voctocore/experiments/startuptest/startuptest.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'voctocore/experiments') diff --git a/voctocore/experiments/startuptest/startuptest.py b/voctocore/experiments/startuptest/startuptest.py index 6e1802e..606f5b5 100755 --- a/voctocore/experiments/startuptest/startuptest.py +++ b/voctocore/experiments/startuptest/startuptest.py @@ -14,7 +14,7 @@ # but somehow this is not enough to make the pipeline start in an error-condition.. # -import gi +import gi, time # import GStreamer and GTK-Helper classes gi.require_version('Gst', '1.0') @@ -44,6 +44,10 @@ class Example: self.src.link(self.sink) def run(self): + print("PAUSED") + self.pipeline.set_state(Gst.State.PAUSED) + time.sleep(0.1) + print("PLAYING") self.pipeline.set_state(Gst.State.PLAYING) self.mainloop.run() -- cgit v1.2.3