* Fix a problem with the first sample when down sampling.
[ffmpeg.git] / libavcodec / resample.c
index 94e3a56..78b4ad8 100644 (file)
@@ -48,7 +48,7 @@ static void init_mono_resample(ReSampleChannelContext *s, float ratio)
     if (s->iratio == 0)
         s->iratio = 1;
     s->incr = (int)((ratio / s->iratio) * FRAC);
-    s->frac = 0;
+    s->frac = FRAC;
     s->last_sample = 0;
     s->icount = s->iratio;
     s->isum = 0;