Go to the documentation of this file.
30 int min_stride = (par->
width * bpc + 7) >> 3;
31 int with_pal_size = min_stride * par->
height + 1024;
32 int contains_pal = bpc == 8 &&
pkt->
size == with_pal_size;
35 int padding = expected_stride -
FFMIN(expected_stride,
stride);
56 for (y = 0; y<par->
height; y++) {
58 memset(new_pkt->
data + y*expected_stride + expected_stride - padding, 0, padding);
62 return 1 + contains_pal;
Filter the word “frame” indicates either a video frame or a group of audio as stored in an AVFrame structure Format for each input and each output the list of supported formats For video that means pixel format For audio that means channel sample they are references to shared objects When the negotiation mechanism computes the intersection of the formats supported at each end of a all references to both lists are replaced with a reference to the intersection And when a single format is eventually chosen for a link amongst the remaining all references to the list are updated That means that if a filter requires that its input and output have the same format amongst a supported all it has to do is use a reference to the same list of formats query_formats can leave some formats unset and return AVERROR(EAGAIN) to cause the negotiation mechanism toagain later. That can be used by filters with complex requirements to use the format negotiated on one link to set the formats supported on another. Frame references ownership and permissions
This struct describes the properties of an encoded stream.
void av_packet_free(AVPacket **pkt)
Free the packet, if the packet is reference counted, it will be unreferenced first.
int av_new_packet(AVPacket *pkt, int size)
Allocate the payload of a packet and initialize its fields with default values.
AVPacket * av_packet_alloc(void)
Allocate an AVPacket and set its fields to default values.
int av_packet_copy_props(AVPacket *dst, const AVPacket *src)
Copy only "properties" fields from src to dst.
int ff_reshuffle_raw_rgb(AVFormatContext *s, AVPacket **ppkt, AVCodecParameters *par, int expected_stride)
Reshuffles the lines to use the user specified stride.
int bits_per_coded_sample
The number of bits per sample in the codedwords.
This structure stores compressed data.