[FFmpeg-cvslog] afq: update remaining samples variable.

Michael Niedermayer git at videolan.org
Thu Oct 4 03:09:46 CEST 2012


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Thu Oct  4 02:36:58 2012 +0200| [b27e2b6e12461b0f60204c7f0145609a6db1697b] | committer: Michael Niedermayer

afq: update remaining samples variable.

Fixes Ticket1785 (opusenc used this variable)

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b27e2b6e12461b0f60204c7f0145609a6db1697b
---

 libavcodec/audio_frame_queue.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/audio_frame_queue.c b/libavcodec/audio_frame_queue.c
index cc1fd13..a5c22ce 100644
--- a/libavcodec/audio_frame_queue.c
+++ b/libavcodec/audio_frame_queue.c
@@ -95,6 +95,7 @@ void ff_af_queue_remove(AudioFrameQueue *afq, int nb_samples, int64_t *pts,
         if(afq->frames[i].pts != AV_NOPTS_VALUE)
             afq->frames[i].pts      += n;
     }
+    afq->remaining_samples -= removed_samples;
     i -= i && afq->frames[i-1].duration;
     memmove(afq->frames, afq->frames + i, sizeof(*afq->frames) * (afq->frame_count - i));
     afq->frame_count -= i;



More information about the ffmpeg-cvslog mailing list