Go to the documentation of this file.
110 if (!buffer_pkt->data ||
120 if (err < 0 && err !=
AVERROR(EAGAIN))
133 if (!
ctx->in || !
ctx->pkt)
160 .
name =
"av1_frame_merge",
static enum AVCodecID av1_frame_merge_codec_ids[]
void av_packet_unref(AVPacket *pkt)
Wipe the packet.
const AVBitStreamFilter ff_av1_frame_merge_bsf
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
static int av1_frame_merge_filter(AVBSFContext *bsf, AVPacket *out)
#define AVERROR_EOF
End of file.
void * content
Pointer to the decomposed form of this unit.
void ff_cbs_fragment_reset(CodedBitstreamFragment *frag)
Free the units contained in a fragment as well as the fragment's own data buffer, but not the units a...
Context structure for coded bitstream operations.
void ff_cbs_close(CodedBitstreamContext **ctx_ptr)
Close a context and free all internal state.
CodedBitstreamUnitType type
Codec-specific type of this unit.
filter_frame For filters that do not use the this method is called when a frame is pushed to the filter s input It can be called at any time except in a reentrant way If the input frame is enough to produce then the filter should push the output frames on the output link immediately As an exception to the previous rule if the input frame is enough to produce several output frames then the filter needs output only at least one per link The additional frames can be left buffered in the filter
@ AV1_OBU_TEMPORAL_DELIMITER
void av_packet_free(AVPacket **pkt)
Free the packet, if the packet is reference counted, it will be unreferenced first.
The bitstream filter state.
void ff_cbs_fragment_free(CodedBitstreamFragment *frag)
Free the units array of a fragment in addition to what ff_cbs_fragment_reset does.
static void av1_frame_merge_flush(AVBSFContext *bsf)
CodedBitstreamUnit * units
Pointer to an array of units of length nb_units_allocated.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
Coded bitstream fragment structure, combining one or more units.
int ff_cbs_write_packet(CodedBitstreamContext *ctx, AVPacket *pkt, CodedBitstreamFragment *frag)
Write the bitstream of a fragment to a packet.
static void flush(AVCodecContext *avctx)
int ff_cbs_insert_unit_content(CodedBitstreamFragment *frag, int position, CodedBitstreamUnitType type, void *content, AVBufferRef *content_buf)
Insert a new unit into a fragment with the given content.
CodedBitstreamContext * input
void av_packet_move_ref(AVPacket *dst, AVPacket *src)
Move every field in src to dst and reset src.
AVCodecID
Identify the syntax and semantics of the bitstream.
static void av1_frame_merge_close(AVBSFContext *bsf)
#define AV_NOPTS_VALUE
Undefined timestamp value.
AVPacket * av_packet_alloc(void)
Allocate an AVPacket and set its fields to default values.
CodedBitstreamFragment frag[2]
static int av1_frame_merge_init(AVBSFContext *bsf)
#define i(width, name, range_min, range_max)
int64_t pts
Presentation timestamp in AVStream->time_base units; the time at which the decompressed packet will b...
void * priv_data
Opaque filter-specific private data.
AVBufferRef * content_ref
If content is reference counted, a reference to the buffer containing content.
int ff_cbs_init(CodedBitstreamContext **ctx_ptr, enum AVCodecID codec_id, void *log_ctx)
Create and initialise a new context for the given codec.
int ff_cbs_read_packet(CodedBitstreamContext *ctx, CodedBitstreamFragment *frag, const AVPacket *pkt)
Read the data bitstream from a packet into a fragment, then split into units and decompose.
static enum AVCodecID codec_ids[]
This structure stores compressed data.
int ff_bsf_get_packet_ref(AVBSFContext *ctx, AVPacket *pkt)
Called by bitstream filters to get packet for filtering.
#define AVERROR_INVALIDDATA
Invalid data found when processing input.
CodedBitstreamContext * output
int nb_units
Number of units in this fragment.