Union AVFilter__bindgen_ty_1
#[repr(C)]
pub union AVFilter__bindgen_ty_1 {
pub query_func: Option<unsafe extern "C" fn(*mut AVFilterContext) -> i32>,
pub query_func2: Option<unsafe extern "C" fn(*const AVFilterContext, *mut *mut AVFilterFormatsConfig, *mut *mut AVFilterFormatsConfig) -> i32>,
pub pixels_list: *const i32,
pub samples_list: *const i32,
pub pix_fmt: i32,
pub sample_fmt: i32,
}
Expand description
The state of the following union is determined by formats_state. See the documentation of enum FilterFormatsState in internal.h.
Fields§
§query_func: Option<unsafe extern "C" fn(*mut AVFilterContext) -> i32>
Query formats supported by the filter on its inputs and outputs.
This callback is called after the filter is initialized (so the inputs and outputs are fixed), shortly before the format negotiation. This callback may be called more than once.
This callback must set ::AVFilterLink’s @ref AVFilterFormatsConfig.formats “outcfg.formats” on every input link and @ref AVFilterFormatsConfig.formats “incfg.formats” on every output link to a list of pixel/sample formats that the filter supports on that link. For video links, this filter may also set @ref AVFilterFormatsConfig.color_spaces “incfg.color_spaces” / @ref AVFilterFormatsConfig.color_spaces “outcfg.color_spaces” and @ref AVFilterFormatsConfig.color_ranges “incfg.color_ranges” / @ref AVFilterFormatsConfig.color_ranges “outcfg.color_ranges” analogously. For audio links, this filter must also set @ref AVFilterFormatsConfig.samplerates “incfg.samplerates” / @ref AVFilterFormatsConfig.samplerates “outcfg.samplerates” and @ref AVFilterFormatsConfig.channel_layouts “incfg.channel_layouts” / @ref AVFilterFormatsConfig.channel_layouts “outcfg.channel_layouts” analogously.
This callback must never be NULL if the union is in this state.
@return zero on success, a negative value corresponding to an AVERROR code otherwise
query_func2: Option<unsafe extern "C" fn(*const AVFilterContext, *mut *mut AVFilterFormatsConfig, *mut *mut AVFilterFormatsConfig) -> i32>
Same as query_func(), except this function writes the results into provided arrays.
@param cfg_in array of input format configurations with as many members as the filters has inputs (NULL when there are no inputs); @param cfg_out array of output format configurations with as many members as the filters has outputs (NULL when there are no outputs);
pixels_list: *const i32
A pointer to an array of admissible pixel formats delimited by AV_PIX_FMT_NONE. The generic code will use this list to indicate that this filter supports each of these pixel formats, provided that all inputs and outputs use the same pixel format.
In addition to that the generic code will mark all inputs and all outputs as supporting all color spaces and ranges, as long as all inputs and outputs use the same color space/range.
This list must never be NULL if the union is in this state. The type of all inputs and outputs of filters using this must be AVMEDIA_TYPE_VIDEO.
samples_list: *const i32
Analogous to pixels, but delimited by AV_SAMPLE_FMT_NONE and restricted to filters that only have AVMEDIA_TYPE_AUDIO inputs and outputs.
In addition to that the generic code will mark all inputs and all outputs as supporting all sample rates and every channel count and channel layout, as long as all inputs and outputs use the same sample rate and channel count/layout.
pix_fmt: i32
Equivalent to { pix_fmt, AV_PIX_FMT_NONE } as pixels_list.
sample_fmt: i32
Equivalent to { sample_fmt, AV_SAMPLE_FMT_NONE } as samples_list.
Trait Implementations§
§impl Clone for AVFilter__bindgen_ty_1
impl Clone for AVFilter__bindgen_ty_1
§fn clone(&self) -> AVFilter__bindgen_ty_1
fn clone(&self) -> AVFilter__bindgen_ty_1
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more