From: Wim Taymans Date: Wed, 25 Nov 2009 16:26:16 +0000 (-0600) Subject: audiosink: add adjustement when slaving X-Git-Tag: 1.19.3~511^2~8944 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=75c5aed1ba350e787af909df4c851aa83c15ba9c;p=platform%2Fupstream%2Fgstreamer.git audiosink: add adjustement when slaving Our calibration against the pipeline clock is done with the adjusted ringbuffer time, so take the adjustement into account. Fixes some audio dropouts when reusing audio sinks after switching clocks and slaving methods in a pipeline. --- diff --git a/gst-libs/gst/audio/gstbaseaudiosink.c b/gst-libs/gst/audio/gstbaseaudiosink.c index a4d2dc8..a58e128 100644 --- a/gst-libs/gst/audio/gstbaseaudiosink.c +++ b/gst-libs/gst/audio/gstbaseaudiosink.c @@ -995,6 +995,7 @@ gst_base_audio_sink_skew_slaving (GstBaseAudioSink * sink, /* sample clocks and figure out clock skew */ etime = gst_clock_get_time (GST_ELEMENT_CLOCK (sink)); itime = gst_audio_clock_get_time (sink->provided_clock); + itime = gst_audio_clock_adjust (sink->provided_clock, itime); GST_DEBUG_OBJECT (sink, "internal %" GST_TIME_FORMAT " external %" GST_TIME_FORMAT