diff options
author | MaZderMind <git@mazdermind.de> | 2016-01-28 11:22:26 +0100 |
---|---|---|
committer | MaZderMind <git@mazdermind.de> | 2016-02-02 16:05:56 +0100 |
commit | c64ce93a9f2a85bcaafe8fddf1b591f1ba618d32 (patch) | |
tree | b8113e2f7a8eb566d91e0e73632130bdd2c178ee /example-scripts | |
parent | 60e205cb92e7127742b42ff0e5c0bbc06df1d0e5 (diff) |
wait until clock-sync
Diffstat (limited to 'example-scripts')
-rwxr-xr-x | example-scripts/gstreamer/source-videotestsrc-as-cam1-with-networktime.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/example-scripts/gstreamer/source-videotestsrc-as-cam1-with-networktime.py b/example-scripts/gstreamer/source-videotestsrc-as-cam1-with-networktime.py index b07bf55..441a129 100755 --- a/example-scripts/gstreamer/source-videotestsrc-as-cam1-with-networktime.py +++ b/example-scripts/gstreamer/source-videotestsrc-as-cam1-with-networktime.py @@ -25,10 +25,13 @@ class Source(object): tcpclientsink host=127.0.0.1 port=10000 """ - clock = Gst.SystemClock.obtain() - self.clock = GstNet.NetClientClock.new('voctocore', '127.0.0.1', 9998, clock.get_time()) + self.clock = GstNet.NetClientClock.new('voctocore', '127.0.0.1', 9998, 0) print('obtained NetClientClock from host', self.clock) + print('waiting for NetClientClock to sync…') + self.clock.wait_for_sync(Gst.CLOCK_TIME_NONE) + + print('starting pipeline') self.senderPipeline = Gst.parse_launch(pipeline) self.senderPipeline.use_clock(self.clock) self.src = self.senderPipeline.get_by_name('src') |