FFmpeg
Macros | Functions | Variables
h264_sei.c File Reference
#include <limits.h>
#include <stdio.h>
#include <string.h>
#include "libavutil/error.h"
#include "libavutil/log.h"
#include "libavutil/macros.h"
#include "libavutil/mem.h"
#include "atsc_a53.h"
#include "get_bits.h"
#include "golomb.h"
#include "h264_ps.h"
#include "h264_sei.h"
#include "sei.h"

Go to the source code of this file.

Macros

#define AVERROR_PS_NOT_FOUND   FFERRTAG(0xF8,'?','P','S')
 

Functions

void ff_h264_sei_uninit (H264SEIContext *h)
 Reset SEI values at the beginning of the frame. More...
 
int ff_h264_sei_process_picture_timing (H264SEIPictureTiming *h, const SPS *sps, void *logctx)
 Parse the contents of a picture timing message given an active SPS. More...
 
static int decode_picture_timing (H264SEIPictureTiming *h, GetBitContext *gb, void *logctx)
 
static int decode_registered_user_data_afd (H264SEIAFD *h, GetBitContext *gb, int size)
 
static int decode_registered_user_data_closed_caption (H264SEIA53Caption *h, GetBitContext *gb, void *logctx, int size)
 
static int decode_registered_user_data (H264SEIContext *h, GetBitContext *gb, void *logctx, int size)
 
static int decode_unregistered_user_data (H264SEIUnregistered *h, GetBitContext *gb, void *logctx, int size)
 
static int decode_recovery_point (H264SEIRecoveryPoint *h, GetBitContext *gb, void *logctx)
 
static int decode_buffering_period (H264SEIBufferingPeriod *h, GetBitContext *gb, const H264ParamSets *ps, void *logctx)
 
static int decode_frame_packing_arrangement (H264SEIFramePacking *h, GetBitContext *gb)
 
static int decode_display_orientation (H264SEIDisplayOrientation *h, GetBitContext *gb)
 
static int decode_green_metadata (H264SEIGreenMetaData *h, GetBitContext *gb)
 
static int decode_alternative_transfer (H264SEIAlternativeTransfer *h, GetBitContext *gb)
 
static int decode_film_grain_characteristics (H264SEIFilmGrainCharacteristics *h, GetBitContext *gb)
 
int ff_h264_sei_decode (H264SEIContext *h, GetBitContext *gb, const H264ParamSets *ps, void *logctx)
 
const char * ff_h264_sei_stereo_mode (const H264SEIFramePacking *h)
 Get stereo_mode string from the h264 frame_packing_arrangement. More...
 

Variables

static const uint8_t sei_num_clock_ts_table [9]
 

Detailed Description

H.264 / AVC / MPEG-4 part10 SEI decoding.

Author
Michael Niedermayer micha.nosp@m.elni.nosp@m.@gmx..nosp@m.at

Definition in file h264_sei.c.

Macro Definition Documentation

◆ AVERROR_PS_NOT_FOUND

#define AVERROR_PS_NOT_FOUND   FFERRTAG(0xF8,'?','P','S')

Definition at line 42 of file h264_sei.c.

Function Documentation

◆ ff_h264_sei_uninit()

void ff_h264_sei_uninit ( H264SEIContext h)

Reset SEI values at the beginning of the frame.

Definition at line 48 of file h264_sei.c.

Referenced by decode_nal_units(), h264_close(), h264_decode_end(), h264_decode_flush(), h264_init_context(), and parse_nal_units().

◆ ff_h264_sei_process_picture_timing()

int ff_h264_sei_process_picture_timing ( H264SEIPictureTiming h,
const SPS sps,
void *  logctx 
)

Parse the contents of a picture timing message given an active SPS.

Definition at line 69 of file h264_sei.c.

Referenced by h264_export_frame_props(), and parse_nal_units().

◆ decode_picture_timing()

static int decode_picture_timing ( H264SEIPictureTiming h,
GetBitContext gb,
void *  logctx 
)
static

Definition at line 136 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_registered_user_data_afd()

static int decode_registered_user_data_afd ( H264SEIAFD h,
GetBitContext gb,
int  size 
)
static

Definition at line 159 of file h264_sei.c.

Referenced by decode_registered_user_data().

◆ decode_registered_user_data_closed_caption()

static int decode_registered_user_data_closed_caption ( H264SEIA53Caption h,
GetBitContext gb,
void *  logctx,
int  size 
)
static

Definition at line 180 of file h264_sei.c.

Referenced by decode_registered_user_data().

◆ decode_registered_user_data()

static int decode_registered_user_data ( H264SEIContext h,
GetBitContext gb,
void *  logctx,
int  size 
)
static

Definition at line 190 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_unregistered_user_data()

static int decode_unregistered_user_data ( H264SEIUnregistered h,
GetBitContext gb,
void *  logctx,
int  size 
)
static

Definition at line 251 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_recovery_point()

static int decode_recovery_point ( H264SEIRecoveryPoint h,
GetBitContext gb,
void *  logctx 
)
static

Definition at line 287 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_buffering_period()

static int decode_buffering_period ( H264SEIBufferingPeriod h,
GetBitContext gb,
const H264ParamSets ps,
void *  logctx 
)
static

Definition at line 305 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_frame_packing_arrangement()

static int decode_frame_packing_arrangement ( H264SEIFramePacking h,
GetBitContext gb 
)
static

Definition at line 342 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_display_orientation()

static int decode_display_orientation ( H264SEIDisplayOrientation h,
GetBitContext gb 
)
static

Definition at line 370 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_green_metadata()

static int decode_green_metadata ( H264SEIGreenMetaData h,
GetBitContext gb 
)
static

Definition at line 387 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_alternative_transfer()

static int decode_alternative_transfer ( H264SEIAlternativeTransfer h,
GetBitContext gb 
)
static

Definition at line 412 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ decode_film_grain_characteristics()

static int decode_film_grain_characteristics ( H264SEIFilmGrainCharacteristics h,
GetBitContext gb 
)
static

Definition at line 420 of file h264_sei.c.

Referenced by ff_h264_sei_decode().

◆ ff_h264_sei_decode()

int ff_h264_sei_decode ( H264SEIContext h,
GetBitContext gb,
const H264ParamSets ps,
void *  logctx 
)

Definition at line 463 of file h264_sei.c.

Referenced by decode_nal_units(), and parse_nal_units().

◆ ff_h264_sei_stereo_mode()

const char* ff_h264_sei_stereo_mode ( const H264SEIFramePacking h)

Get stereo_mode string from the h264 frame_packing_arrangement.

Definition at line 546 of file h264_sei.c.

Referenced by output_frame().

Variable Documentation

◆ sei_num_clock_ts_table

const uint8_t sei_num_clock_ts_table[9]
static
Initial value:
= {
1, 1, 1, 2, 2, 3, 3, 2, 3
}

Definition at line 44 of file h264_sei.c.

Referenced by ff_h264_sei_process_picture_timing().