struct AVFrame

Defined at line 330 of file ../../prebuilt/third_party/ffmpeg/pkg/ffmpeg/include/libavutil/frame.h

This structure describes decoded (raw) audio or video data.

AVFrame must be allocated using av_frame_alloc(). Note that this only

allocates the AVFrame itself, the buffers for the data must be managed

through other means (see below).

AVFrame must be freed with av_frame_free().

AVFrame is typically allocated once and then reused multiple times to hold

different data (e.g. a single AVFrame to hold frames received from a

decoder). In such a case, av_frame_unref() will free any references held by

the frame and reset it to its original clean state before it

is reused again.

The data described by an AVFrame is usually reference counted through the

AVBuffer API. The underlying buffer references are stored in AVFrame.buf /

AVFrame.extended_buf. An AVFrame is considered to be reference counted if at

least one reference is set, i.e. if AVFrame.buf[0] != NULL. In such a case,

every single data plane must be contained in one of the buffers in

AVFrame.buf or AVFrame.extended_buf.

There may be a single buffer for all the data, or one separate buffer for

each plane, or anything in between.

sizeof(AVFrame) is not a part of the public ABI, so new fields may be added

to the end with a minor bump.

Fields can be accessed through AVOptions, the name string used, matches the

C structure field name for fields accessible through AVOptions. The AVClass

for AVFrame can be obtained from avcodec_get_frame_class()

Public Members

uint8_t *[8] data
int[8] linesize
uint8_t ** extended_data
int width
int height
int nb_samples
int format
int key_frame
AVPictureType pict_type
AVRational sample_aspect_ratio
int64_t pts
int64_t pkt_dts
AVRational time_base
int coded_picture_number
int display_picture_number
int quality
void * opaque
int repeat_pict
int interlaced_frame
int top_field_first
int palette_has_changed
int64_t reordered_opaque
int sample_rate
uint64_t channel_layout
AVBufferRef *[8] buf
AVBufferRef ** extended_buf
int nb_extended_buf
AVFrameSideData ** side_data
int nb_side_data
int flags
AVColorRange color_range
AVColorPrimaries color_primaries
AVColorTransferCharacteristic color_trc
AVColorSpace colorspace
AVChromaLocation chroma_location
int64_t best_effort_timestamp
int64_t pkt_pos
int64_t pkt_duration
AVDictionary * metadata
int decode_error_flags
int channels
int pkt_size
AVBufferRef * hw_frames_ctx
AVBufferRef * opaque_ref
size_t crop_top
size_t crop_bottom
size_t crop_left
size_t crop_right
AVBufferRef * private_ref
AVChannelLayout ch_layout
int64_t duration