FFmpeg
Loading...
Searching...
No Matches
parser.c File Reference
#include <inttypes.h>
#include <stdint.h>
#include <string.h>
#include "libavutil/attributes.h"
#include "libavutil/avassert.h"
#include "libavutil/mem.h"
#include "codec_desc.h"
#include "parser.h"
#include "parser_internal.h"

Go to the source code of this file.

Macros

#define FILL(name)
 

Functions

av_cold AVCodecParserContextav_parser_init (enum AVCodecID codec_id)
 
void ff_fetch_timestamp (AVCodecParserContext *s, int off, int remove, int fuzzy)
 Fetch timestamps for a specific byte within the current access unit.
 
int av_parser_parse2 (AVCodecParserContext *s, AVCodecContext *avctx, uint8_t **poutbuf, int *poutbuf_size, const uint8_t *buf, int buf_size, int64_t pts, int64_t dts, int64_t pos)
 Parse a packet.
 
av_cold void av_parser_close (AVCodecParserContext *s)
 
int ff_combine_frame (ParseContext *pc, int next, const uint8_t **buf, int *buf_size)
 Combine the (truncated) bitstream to a complete frame.
 
av_cold void ff_parse_close (AVCodecParserContext *s)
 

Macro Definition Documentation

◆ FILL

#define FILL ( name)
Value:
if(s->name > 0 && avctx->name <= 0) avctx->name = s->name
#define s(width, name)
Definition cbs_vp9.c:198

Referenced by av_parser_parse2().

Function Documentation

◆ ff_fetch_timestamp()

void ff_fetch_timestamp ( AVCodecParserContext * s,
int off,
int remove,
int fuzzy )

Fetch timestamps for a specific byte within the current access unit.

Parameters
offbyte position within the access unit
removeFound timestamps will be removed if set to 1, kept if set to 0.
fuzzyOnly use found value if it is more informative than what we already have

Definition at line 89 of file parser.c.

Referenced by av_parser_parse2(), and mpeg1_find_frame_end().

◆ ff_combine_frame()

◆ ff_parse_close()

av_cold void ff_parse_close ( AVCodecParserContext * s)

Definition at line 300 of file parser.c.