Fixed system clock phase when changing rate.
authorLaurent Aimar <fenrir@videolan.org>
Tue, 21 Oct 2008 22:58:19 +0000 (00:58 +0200)
committerLaurent Aimar <fenrir@videolan.org>
Wed, 22 Oct 2008 20:21:43 +0000 (22:21 +0200)
src/input/clock.c

index beee45e..1655629 100644 (file)
@@ -268,7 +268,10 @@ void input_clock_ChangeRate( input_clock_t *cl, int i_rate )
 
     /* Move the reference point */
     if( cl->b_has_reference )
+    {
+        cl->last.i_system = ClockStreamToSystem( cl, cl->last.i_stream );
         cl->ref = cl->last;
+    }
 
     cl->i_rate = i_rate;