diff options
author | Anuradha Suraparaju <anuradha@rd.bbc.co.uk> | 2008-07-10 11:40:19 +0000 |
---|---|---|
committer | Benoit Fouet <benoit.fouet@free.fr> | 2008-07-10 11:40:19 +0000 |
commit | 0cf0e25d22879462d02979efdf44db28b48f957f (patch) | |
tree | 85be2b24c7d1f041cbd2a86bec7215bf1ddfd474 /libavcodec/libdirac_libschro.c | |
parent | 80150f7ee813849c47f2612378dd2cab3c1d4c98 (diff) | |
download | ffmpeg-0cf0e25d22879462d02979efdf44db28b48f957f.tar.gz |
Add a parameter for queue size.
Patch by Anuradha Suraparaju anuradha rd bbc co uk
Originally committed as revision 14150 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/libdirac_libschro.c')
-rw-r--r-- | libavcodec/libdirac_libschro.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/libdirac_libschro.c b/libavcodec/libdirac_libschro.c index 0b134c42e5..416eb59804 100644 --- a/libavcodec/libdirac_libschro.c +++ b/libavcodec/libdirac_libschro.c @@ -70,6 +70,7 @@ unsigned int ff_dirac_schro_get_video_format_idx (AVCodecContext *avccontext) void ff_dirac_schro_queue_init (FfmpegDiracSchroQueue *queue) { queue->p_head = queue->p_tail = NULL; + queue->size = 0; } void ff_dirac_schro_queue_free (FfmpegDiracSchroQueue *queue, @@ -96,6 +97,7 @@ int ff_dirac_schro_queue_push_back (FfmpegDiracSchroQueue *queue, void *p_data) queue->p_tail->next = p_new; queue->p_tail = p_new; + ++queue->size; return 0; } @@ -106,6 +108,7 @@ void *ff_dirac_schro_queue_pop (FfmpegDiracSchroQueue *queue) if (top != NULL) { void *data = top->data; queue->p_head = queue->p_head->next; + --queue->size; av_freep (&top); return data; } |