22 #ifndef AVFILTER_BUFFERQUEUE_H 23 #define AVFILTER_BUFFERQUEUE_H 39 #ifndef FF_BUFQUEUE_SIZE 40 #define FF_BUFQUEUE_SIZE 64 55 #define BUCKET(i) queue->queue[(queue->head + (i)) % FF_BUFQUEUE_SIZE] static AVFrame * ff_bufqueue_get(struct FFBufQueue *queue)
Get the first buffer from the queue and remove it.
This structure describes decoded (raw) audio or video data.
#define AV_LOG_WARNING
Something somehow does not look correct.
Main libavfilter public API header.
Structure holding the queue.
#define av_assert0(cond)
assert() equivalent, that is always enabled.
void av_frame_free(AVFrame **frame)
Free the frame and any dynamically allocated objects in it, e.g.
simple assert() macros that are a bit more flexible than ISO C assert().
AVFrame * queue[FF_BUFQUEUE_SIZE]
static int ff_bufqueue_is_full(struct FFBufQueue *queue)
Test if a buffer queue is full.
static void ff_bufqueue_discard_all(struct FFBufQueue *queue)
Unref and remove all buffers from the queue.
unsigned short available
number of available buffers
#define FF_BUFQUEUE_SIZE
FFBufQueue: simple AVFrame queue API.
static void ff_bufqueue_add(void *log, struct FFBufQueue *queue, AVFrame *buf)
Add a buffer to the queue.
static AVFrame * ff_bufqueue_peek(struct FFBufQueue *queue, unsigned index)
Get a buffer from the queue without altering it.