Mercurial > libavutil.hg
comparison fifo.c @ 228:a9a6ed6ec73d libavutil
doxygenize
author | michael |
---|---|
date | Wed, 17 Jan 2007 20:12:12 +0000 |
parents | 158b400d2f75 |
children | 3f5c648b82c4 |
comparison
equal
deleted
inserted
replaced
227:158b400d2f75 | 228:a9a6ed6ec73d |
---|---|
83 size -= len; | 83 size -= len; |
84 } | 84 } |
85 } | 85 } |
86 | 86 |
87 | 87 |
88 /* get data from the fifo (return -1 if not enough data) */ | 88 /** get data from the fifo (return -1 if not enough data) */ |
89 int av_fifo_generic_read(AVFifoBuffer *f, int buf_size, void (*func)(void*, void*, int), void* dest) | 89 int av_fifo_generic_read(AVFifoBuffer *f, int buf_size, void (*func)(void*, void*, int), void* dest) |
90 { | 90 { |
91 int size = av_fifo_size(f); | 91 int size = av_fifo_size(f); |
92 | 92 |
93 if (size < buf_size) | 93 if (size < buf_size) |
103 buf_size -= len; | 103 buf_size -= len; |
104 } | 104 } |
105 return 0; | 105 return 0; |
106 } | 106 } |
107 | 107 |
108 /* discard data from the fifo */ | 108 /** discard data from the fifo */ |
109 void av_fifo_drain(AVFifoBuffer *f, int size) | 109 void av_fifo_drain(AVFifoBuffer *f, int size) |
110 { | 110 { |
111 f->rptr += size; | 111 f->rptr += size; |
112 if (f->rptr >= f->end) | 112 if (f->rptr >= f->end) |
113 f->rptr -= f->end - f->buffer; | 113 f->rptr -= f->end - f->buffer; |