[−][src]Struct ffmpeg_sys_next::AVCodec
AVCodec.
Fields
name: *const c_char
Name of the codec implementation. The name is globally unique among encoders and among decoders (but an encoder and a decoder can share the same name). This is the primary way to find a codec from the user perspective.
long_name: *const c_char
Descriptive name for the codec, meant to be more human readable than name. You should use the NULL_IF_CONFIG_SMALL() macro to define it.
type_: AVMediaType
id: AVCodecID
capabilities: c_int
Codec capabilities. see AV_CODEC_CAP_*
supported_framerates: *const AVRational
< array of supported framerates, or NULL if any, array is terminated by {0,0}
pix_fmts: *const AVPixelFormat
< array of supported pixel formats, or NULL if unknown, array is terminated by -1
supported_samplerates: *const c_int
< array of supported audio samplerates, or NULL if unknown, array is terminated by 0
sample_fmts: *const AVSampleFormat
< array of supported sample formats, or NULL if unknown, array is terminated by -1
channel_layouts: *const u64
< array of support channel layouts, or NULL if unknown. array is terminated by 0
max_lowres: u8
< maximum value for lowres supported by the decoder
priv_class: *const AVClass
< AVClass for the private context
profiles: *const AVProfile
< array of recognized profiles, or NULL if unknown, array is terminated by {FF_PROFILE_UNKNOWN}
wrapper_name: *const c_char
Group name of the codec implementation. This is a short symbolic name of the wrapper backing this codec. A wrapper uses some kind of external implementation for the codec, such as an external library, or a codec implementation provided by the OS or the hardware. If this field is NULL, this is a builtin, libavcodec native codec. If non-NULL, this will be the suffix in AVCodec.name in most cases (usually AVCodec.name will be of the form "<codec_name>_<wrapper_name>").
priv_data_size: c_int
No fields below this line are part of the public API. They may not be used outside of libavcodec and can be changed and removed at will. New public fields should be added right above.
next: *mut AVCodec
init_thread_copy: Option<unsafe extern "C" fn(arg1: *mut AVCodecContext) -> c_int>
@name Frame-level threading support functions @{ If defined, called on thread contexts when they are created. If the codec allocates writable tables in init(), re-allocate them here. priv_data will be set to a copy of the original.
update_thread_context: Option<unsafe extern "C" fn(dst: *mut AVCodecContext, src: *const AVCodecContext) -> c_int>
Copy necessary context variables from a previous thread context to the current one. If not defined, the next thread will start automatically; otherwise, the codec must call ff_thread_finish_setup().
dst and src will (rarely) point to the same context, in which case memcpy should be skipped.
defaults: *const AVCodecDefault
Private codec-specific defaults.
init_static_data: Option<unsafe extern "C" fn(codec: *mut AVCodec)>
Initialize codec static data, called from avcodec_register().
This is not intended for time consuming operations as it is run for every codec regardless of that codec being used.
init: Option<unsafe extern "C" fn(arg1: *mut AVCodecContext) -> c_int>
encode_sub: Option<unsafe extern "C" fn(arg1: *mut AVCodecContext, buf: *mut u8, buf_size: c_int, sub: *const AVSubtitle) -> c_int>
encode2: Option<unsafe extern "C" fn(avctx: *mut AVCodecContext, avpkt: *mut AVPacket, frame: *const AVFrame, got_packet_ptr: *mut c_int) -> c_int>
Encode data to an AVPacket.
@param avctx codec context @param avpkt output AVPacket (may contain a user-provided buffer) @param[in] frame AVFrame containing the raw data to be encoded @param[out] got_packet_ptr encoder sets to 0 or 1 to indicate that a non-empty packet was returned in avpkt. @return 0 on success, negative error code on failure
decode: Option<unsafe extern "C" fn(arg1: *mut AVCodecContext, outdata: *mut c_void, outdata_size: *mut c_int, avpkt: *mut AVPacket) -> c_int>
close: Option<unsafe extern "C" fn(arg1: *mut AVCodecContext) -> c_int>
send_frame: Option<unsafe extern "C" fn(avctx: *mut AVCodecContext, frame: *const AVFrame) -> c_int>
Encode API with decoupled packet/frame dataflow. The API is the same as the avcodec_ prefixed APIs (avcodec_send_frame() etc.), except that:
- never called if the codec is closed or the wrong type,
- if AV_CODEC_CAP_DELAY is not set, drain frames are never sent,
- only one drain frame is ever passed down,
receive_packet: Option<unsafe extern "C" fn(avctx: *mut AVCodecContext, avpkt: *mut AVPacket) -> c_int>
receive_frame: Option<unsafe extern "C" fn(avctx: *mut AVCodecContext, frame: *mut AVFrame) -> c_int>
Decode API with decoupled packet/frame dataflow. This function is called to get one output frame. It should call ff_decode_get_packet() to obtain input data.
flush: Option<unsafe extern "C" fn(arg1: *mut AVCodecContext)>
Flush buffers. Will be called when seeking
caps_internal: c_int
Internal codec capabilities. See FF_CODEC_CAP_* in internal.h
bsfs: *const c_char
Decoding only, a comma-separated list of bitstream filters to apply to packets before decoding.
hw_configs: *mut *mut AVCodecHWConfigInternal
Array of pointers to hardware configurations supported by the codec, or NULL if no hardware supported. The array is terminated by a NULL pointer.
The user can only access this field via avcodec_get_hw_config().
Trait Implementations
impl Clone for AVCodec
[src]
impl Copy for AVCodec
[src]
impl Debug for AVCodec
[src]
impl Eq for AVCodec
[src]
impl PartialEq<AVCodec> for AVCodec
[src]
impl StructuralEq for AVCodec
[src]
impl StructuralPartialEq for AVCodec
[src]
Auto Trait Implementations
impl RefUnwindSafe for AVCodec
impl !Send for AVCodec
impl !Sync for AVCodec
impl Unpin for AVCodec
impl UnwindSafe for AVCodec
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,