FFmpeg
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Fields
AVFilterPad Struct Reference

A filter pad used for either input or output. More...

#include <internal.h>

Data Fields

const char * name
 Pad name.
 
enum AVMediaType type
 AVFilterPad type.
 
int min_perms
 Minimum required permissions on incoming buffers.
 
int rej_perms
 Permissions which are not accepted on incoming buffers.
 
AVFilterBufferRef *(* get_video_buffer )(AVFilterLink *link, int perms, int w, int h)
 Callback function to get a video buffer.
 
AVFilterBufferRef *(* get_audio_buffer )(AVFilterLink *link, int perms, int nb_samples)
 Callback function to get an audio buffer.
 
int(* filter_frame )(AVFilterLink *link, AVFilterBufferRef *frame)
 Filtering callback.
 
int(* poll_frame )(AVFilterLink *link)
 Frame poll callback.
 
int(* request_frame )(AVFilterLink *link)
 Frame request callback.
 
int(* config_props )(AVFilterLink *link)
 Link configuration callback.
 
int needs_fifo
 The filter expects a fifo to be inserted on its input link, typically because it has a delay.
 

Detailed Description

A filter pad used for either input or output.

Definition at line 57 of file internal.h.

Field Documentation

const char* AVFilterPad::name

Pad name.

The name is unique among inputs and among outputs, but an input may have the same name as an output. This may be NULL if this pad has no need to ever be referenced by name.

Definition at line 63 of file internal.h.

Referenced by avfilter_graph_dump_to_buf(), avfilter_graph_request_oldest(), avfilter_pad_get_name(), avfilter_register(), close_input(), config_output(), graph_check_validity(), init(), join_init(), join_uninit(), movie_common_init(), movie_uninit(), pad_count(), print_digraph(), process_frame(), show_filters(), split_init(), split_uninit(), and uninit().

enum AVMediaType AVFilterPad::type
int AVFilterPad::min_perms

Minimum required permissions on incoming buffers.

Any buffer with insufficient permissions will be automatically copied by the filter system to a new buffer which provides the needed access permissions.

Input pads only.

Definition at line 77 of file internal.h.

Referenced by ff_filter_frame_framed(), and ff_filter_frame_needs_framing().

int AVFilterPad::rej_perms

Permissions which are not accepted on incoming buffers.

Any buffer which has any of these permissions set will be automatically copied by the filter system to a new buffer which does not have those permissions. This can be used to easily disallow buffers with AV_PERM_REUSE.

Input pads only.

Definition at line 88 of file internal.h.

Referenced by ff_filter_frame_framed(), and split_init().

AVFilterBufferRef*(* AVFilterPad::get_video_buffer)(AVFilterLink *link, int perms, int w, int h)

Callback function to get a video buffer.

If NULL, the filter system will use ff_default_get_video_buffer().

Input video pads only.

Definition at line 96 of file internal.h.

Referenced by ff_get_video_buffer().

AVFilterBufferRef*(* AVFilterPad::get_audio_buffer)(AVFilterLink *link, int perms, int nb_samples)

Callback function to get an audio buffer.

If NULL, the filter system will use ff_default_get_audio_buffer().

Input audio pads only.

Definition at line 104 of file internal.h.

Referenced by ff_get_audio_buffer().

int(* AVFilterPad::filter_frame)(AVFilterLink *link, AVFilterBufferRef *frame)

Filtering callback.

This is where a filter receives a frame with audio/video data and should do its processing.

Input pads only.

Returns
>= 0 on success, a negative AVERROR on error. This function must ensure that samplesref is properly unreferenced on error if it hasn't been passed on to another filter.

Definition at line 117 of file internal.h.

Referenced by av_buffersink_read(), av_buffersink_read_samples(), avfilter_register(), ff_filter_frame_framed(), init(), and join_init().

int(* AVFilterPad::poll_frame)(AVFilterLink *link)

Frame poll callback.

This returns the number of immediately available samples. It should return a positive value if the next request_frame() is guaranteed to return one frame (with no delay).

Defaults to just calling the source poll_frame() method.

Output pads only.

Definition at line 128 of file internal.h.

Referenced by ff_poll_frame().

int(* AVFilterPad::request_frame)(AVFilterLink *link)

Frame request callback.

A call to this should result in at least one frame being output over the given link. This should return zero on success, and another value on error.

Output pads only.

Definition at line 137 of file internal.h.

Referenced by av_buffersrc_add_ref(), ff_request_frame(), and movie_common_init().

int(* AVFilterPad::config_props)(AVFilterLink *link)

Link configuration callback.

For output pads, this should set the link properties such as width/height. This should NOT set the format property - that is negotiated between filters by the filter system using the query_formats() callback before this function is called.

For input pads, this should check the properties of the link, and update the filter's internal state as necessary.

For both input and output filters, this should return zero on success, and another value on error.

Definition at line 153 of file internal.h.

Referenced by avfilter_config_links(), and movie_common_init().

int AVFilterPad::needs_fifo

The filter expects a fifo to be inserted on its input link, typically because it has a delay.

input pads only.

Definition at line 161 of file internal.h.

Referenced by graph_insert_fifos(), and join_init().


The documentation for this struct was generated from the following file: