142 #define INTERLACE_TYPE_P 0
143 #define INTERLACE_TYPE_T 1
144 #define INTERLACE_TYPE_B 2
178 #define D2TS(d) (isnan(d) ? AV_NOPTS_VALUE : (int64_t)(d))
179 #define TS2D(ts) ((ts) == AV_NOPTS_VALUE ? NAN : (double)(ts))
225 "Buffering limit reached, cannot cache more frames\n");
228 sizeof(picref),
NULL);
int av_fifo_generic_read(AVFifoBuffer *f, void *dest, int buf_size, void(*func)(void *, void *, int))
Feed data from an AVFifoBuffer to a user-supplied callback.
int av_fifo_size(AVFifoBuffer *f)
Return the amount of data in bytes in the AVFifoBuffer, that is the amount of data you can read from ...
AVFilterBufferRefVideoProps * video
video buffer specific properties
static int select_frame(AVFilterContext *ctx, AVFilterBufferRef *picref)
int h
agreed upon image height
static const char * var_names[]
static int config_input(AVFilterLink *inlink)
int av_expr_parse(AVExpr **expr, const char *s, const char *const *const_names, const char *const *func1_names, double(*const *funcs1)(void *, double), const char *const *func2_names, double(*const *funcs2)(void *, double, double), int log_offset, void *log_ctx)
Parse an expression.
AVFilterLink ** inputs
array of pointers to input links
static av_cold int init(AVFilterContext *ctx, const char *args, void *opaque)
int top_field_first
field order
AVFilter avfilter_vf_select
void avfilter_end_frame(AVFilterLink *link)
Notifie the next filter that the current frame has finished.
int av_fifo_generic_write(AVFifoBuffer *f, void *src, int size, int(*func)(void *, void *, int))
Feed data from a user-supplied callback to an AVFifoBuffer.
static double av_q2d(AVRational a)
Convert rational to double.
static void start_frame(AVFilterLink *inlink, AVFilterBufferRef *picref)
int64_t pts
presentation timestamp.
A filter pad used for either input or output.
AVFifoBuffer * av_fifo_alloc(unsigned int size)
Initialize an AVFifoBuffer.
A link between two filters.
double var_values[VAR_VARS_NB]
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification. ...
void * priv
private data for use by the filter
AVRational time_base
Define the time base used by the PTS of the frames/samples which will pass through this link...
void av_log(void *avcl, int level, const char *fmt,...)
int avfilter_poll_frame(AVFilterLink *link)
Poll a frame from the filter chain.
int av_fifo_space(AVFifoBuffer *f)
Return the amount of space in bytes in the AVFifoBuffer, that is the amount of data you can write int...
static void end_frame(AVFilterLink *inlink)
AVFilterContext * src
source filter
void avfilter_draw_slice(AVFilterLink *link, int y, int h, int slice_dir)
Send a slice to the next filter.
void av_fifo_free(AVFifoBuffer *f)
Free an AVFifoBuffer.
void avfilter_unref_buffer(AVFilterBufferRef *ref)
Remove a reference to a buffer.
A reference to an AVFilterBuffer.
static int poll_frame(AVFilterLink *outlink)
void av_expr_free(AVExpr *e)
Free a parsed expression previously created with av_expr_parse().
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
a very simple circular buffer FIFO implementation
enum AVPictureType pict_type
picture type of the frame
AVFilterBufferRef * avfilter_ref_buffer(AVFilterBufferRef *ref, int pmask)
Add a new reference to a buffer.
void avfilter_start_frame(AVFilterLink *link, AVFilterBufferRef *picref)
Notify the next filter of the start of a frame.
int avfilter_request_frame(AVFilterLink *link)
Request an input frame from the filter at the other end of the link.
const char * name
filter name
AVFilterBufferRef * avfilter_null_get_video_buffer(AVFilterLink *link, int perms, int w, int h)
get_video_buffer() handler for filters which simply pass video along
AVFilterLink ** outputs
array of pointers to output links
int interlaced
is frame interlaced
static av_cold void uninit(AVFilterContext *ctx)
AVFifoBuffer * pending_frames
FIFO buffer of video frames.
static int request_frame(AVFilterLink *outlink)
int64_t pos
byte position in stream, -1 if unknown
double av_expr_eval(AVExpr *e, const double *const_values, void *opaque)
Evaluate a previously parsed expression.
AVFilterContext * dst
dest filter
AVFilterBufferRef * cur_buf
static void draw_slice(AVFilterLink *inlink, int y, int h, int slice_dir)
simple arithmetic expression evaluator