61 for (;
i < buf_size;
i++) {
72 for(;
i < buf_size;
i++) {
94 const uint8_t **poutbuf,
int *poutbuf_size,
95 const uint8_t *buf,
int buf_size)
115 *poutbuf_size = buf_size;
125 p->cbc->log_ctx = avctx;
127 ret = ff_cbs_read(p->cbc, au,
ref, buf, buf_size);
170 ff_cbs_fragment_reset(au);
173 p->cbc->log_ctx =
NULL;
203 ff_cbs_fragment_free(&p->au);
204 ff_cbs_close(&p->cbc);
static void bit_depth(AudioStatsContext *s, const uint64_t *const mask, uint8_t *depth)
static enum AVPixelFormat apv_format_table[5][4]
static int parse(AVCodecParserContext *s, AVCodecContext *avctx, const uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size)
static void dummy_free(void *opaque, uint8_t *data)
static const CodedBitstreamUnitType decompose_unit_types[]
static int find_frame_end(APVParseContext *p, const uint8_t *buf, int buf_size)
static av_cold void close(AVCodecParserContext *s)
const FFCodecParser ff_apv_parser
simple assert() macros that are a bit more flexible than ISO C assert().
#define av_assert1(cond)
assert() equivalent, that does not lie in speed critical code.
#define av_assert0(cond)
assert() equivalent, that is always enabled.
Libavcodec external API header.
#define PARSER_FLAG_COMPLETE_FRAMES
refcounted data buffer API
#define i(width, name, range_min, range_max)
int(* init)(AVBSFContext *ctx)
static struct @346255127015250356166251341105367306144006377143 state
@ AV_PICTURE_STRUCTURE_FRAME
coded as frame
void av_buffer_unref(AVBufferRef **buf)
Free a given reference and automatically free the buffer if there are no more references to it.
int av_buffer_get_ref_count(const AVBufferRef *buf)
#define AV_BUFFER_FLAG_READONLY
Always treat the buffer as read-only, even when it has only one reference.
AVBufferRef * av_buffer_create(uint8_t *data, size_t size, void(*free)(void *opaque, uint8_t *data), void *opaque, int flags)
Create an AVBuffer from an existing array.
#define AV_LOG_ERROR
Something went wrong and cannot losslessly be recovered.
@ AV_PICTURE_TYPE_I
Intra.
uint32_t CodedBitstreamUnitType
The codec-specific type of a bitstream unit.
Memory handling functions.
int ff_combine_frame(ParseContext *pc, int next, const uint8_t **buf, int *buf_size)
Combine the (truncated) bitstream to a complete frame.
#define PARSER_CODEC_LIST(...)
#define AV_PIX_FMT_YUV444P12
@ AVCHROMA_LOC_TOPLEFT
ITU-R 601, SMPTE 274M 296M S314M(DV 4:1:1), mpeg2 4:2:2.
@ AVCOL_RANGE_MPEG
Narrow or limited range content.
@ AVCOL_RANGE_JPEG
Full range content.
#define AV_PIX_FMT_YUVA444P10
#define AV_PIX_FMT_YUV422P12
#define AV_PIX_FMT_YUV422P10
#define AV_PIX_FMT_GRAY12
AVPixelFormat
Pixel format.
@ AV_PIX_FMT_YUV422P
planar YUV 4:2:2, 16bpp, (1 Cr & Cb sample per 2x1 Y samples)
@ AV_PIX_FMT_GRAY8
Y , 8bpp.
@ AV_PIX_FMT_YUV444P
planar YUV 4:4:4, 24bpp, (1 Cr & Cb sample per 1x1 Y samples)
@ AV_PIX_FMT_YUVA444P
planar YUV 4:4:4 32bpp, (1 Cr & Cb sample per 1x1 Y & A samples)
#define AV_PIX_FMT_GRAY10
#define AV_PIX_FMT_GRAY14
#define AV_PIX_FMT_YUV422P16
#define AV_PIX_FMT_GRAY16
#define AV_PIX_FMT_YUVA444P16
#define AV_PIX_FMT_YUVA444P12
#define AV_PIX_FMT_YUV444P16
#define AV_PIX_FMT_YUV444P10
static const uint8_t header[24]
#define FF_ARRAY_ELEMS(a)
CodedBitstreamContext * cbc
CodedBitstreamFragment au
uint8_t chroma_format_idc
A reference to a data buffer.
main external API structure.
enum AVColorRange color_range
MPEG vs JPEG YUV range.
enum AVColorPrimaries color_primaries
Chromaticity coordinates of the source primaries.
int level
Encoding level descriptor.
enum AVColorSpace colorspace
YUV colorspace type.
enum AVColorTransferCharacteristic color_trc
Color Transfer Characteristic.
enum AVChromaLocation chroma_sample_location
This defines the location of chroma samples.
Context structure for coded bitstream operations.
Coded bitstream fragment structure, combining one or more units.
CodedBitstreamUnit * units
Pointer to an array of units of length nb_units_allocated.
int nb_units
Number of units in this fragment.
Coded bitstream unit structure.
void * content
Pointer to the decomposed form of this unit.
CodedBitstreamUnitType type
Codec-specific type of this unit.
uint32_t state
contains the last few bytes in MSB order
static int ref[MAX_W *MAX_W]