2007-04-05 Wim Taymans <wim@fluendo.com>
+ * gst-libs/gst/audio/gstbaseaudiosink.c:
+ (gst_base_audio_sink_skew_slaving):
+ Don't try to create invalid calibration parameters by making the
+ internal time go backwards, instead make external time go forward.
+
+2007-04-05 Wim Taymans <wim@fluendo.com>
+
Patch by: Tommi Myöhänen <ext-tommi dot myohanen at nokia dot com>
* gst/playback/gstplaybasebin.c: (add_stream):
/* adjust playout pointer based on skew */
if (sink->priv->avg_skew > segtime) {
- /* master is running slower */
+ /* master is running slower, move internal time forward */
GST_WARNING_OBJECT (sink,
"correct clock skew %" G_GINT64_FORMAT " > %" G_GINT64_FORMAT,
sink->priv->avg_skew, segtime);
gst_clock_set_calibration (sink->provided_clock, cinternal, cexternal,
crate_num, crate_denom);
} else if (sink->priv->avg_skew < -segtime) {
- /* master is running faster */
+ /* master is running faster, move external time forwards */
GST_WARNING_OBJECT (sink,
"correct clock skew %" G_GINT64_FORMAT " < %" G_GINT64_FORMAT,
sink->priv->avg_skew, -segtime);
- cinternal -= segtime;
+ cexternal += segtime;
sink->priv->avg_skew += segtime;
sink->next_sample = -1;
gst_clock_set_calibration (sink->provided_clock, cinternal, cexternal,