rdoq.h File Reference

Headerfile for trellis based mode decision. More...

#include <math.h>

Include dependency graph for rdoq.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  est_bits_cabac
struct  level_data_struct

Defines

#define SIGN_BITS   1

Typedefs

typedef struct est_bits_cabac estBitsCabacStruct
typedef struct level_data_struct levelDataStruct

Functions

void init_rdoq_slice (Slice *currSlice)
void est_RunLevel_CAVLC (Macroblock *currMB, levelDataStruct *levelData, int *levelTrellis, int block_type, int b8, int b4, int coeff_num, double lambda)
int est_CAVLC_bits (ImageParameters *p_Img, int level_to_enc[16], int sign_to_enc[16], int nnz, int block_type)
void precalculate_unary_exp_golomb_level (ImageParameters *p_Img)
int est_unary_exp_golomb_level_bits (unsigned int symbol, int bits0, int bits1)
int est_exp_golomb_encode_eq_prob (unsigned int symbol)
void estRunLevel_CABAC (Macroblock *currMB, int context)
int est_write_and_store_CBP_block_bit (Macroblock *currMB, int type)
void est_writeRunLevel_CABAC (Macroblock *currMB, levelDataStruct levelData[], int levelTabMin[], int type, double lambda, int kStart, int kStop, int noCoeff, int estCBP)
void init_trellis_data_4x4_CAVLC (Macroblock *currMB, int **tblock, int block_x, int qp_per, int qp_rem, LevelQuantParams **q_params_4x4, const byte *p_scan, levelDataStruct *dataLevel, int type)
int init_trellis_data_4x4_CABAC (Macroblock *currMB, int **tblock, int block_x, int qp_per, int qp_rem, LevelQuantParams **q_params_4x4, const byte *p_scan, levelDataStruct *dataLevel, int *kStart, int *kStop, int type)
void init_trellis_data_8x8_CAVLC (Macroblock *currMB, int **tblock, int block_x, int qp_per, int qp_rem, LevelQuantParams **q_params_8x8, const byte *p_scan, levelDataStruct levelData[4][16])
int init_trellis_data_8x8_CABAC (Macroblock *currMB, int **tblock, int block_x, int qp_per, int qp_rem, LevelQuantParams **q_params_8x8, const byte *p_scan, levelDataStruct *dataLevel, int *kStart, int *kStop)
void init_trellis_data_DC_CAVLC (Macroblock *currMB, int **tblock, int qp_per, int qp_rem, LevelQuantParams *q_params_4x4, const byte *p_scan, levelDataStruct *dataLevel)
int init_trellis_data_DC_CABAC (Macroblock *currMB, int **tblock, int qp_per, int qp_rem, LevelQuantParams *q_params_4x4, const byte *p_scan, levelDataStruct *dataLevel, int *kStart, int *kStop)
int init_trellis_data_DC_cr_CAVLC (Macroblock *currMB, int **tblock, int qp_per, int qp_rem, LevelQuantParams *q_params_4x4, const byte *p_scan, levelDataStruct *dataLevel)
int init_trellis_data_DC_cr_CABAC (Macroblock *currMB, int **tblock, int qp_per, int qp_rem, LevelQuantParams *q_params_4x4, const byte *p_scan, levelDataStruct *dataLevel, int *kStart, int *kStop)
void RDOQ_update_mode (Slice *currSlice, RD_PARAMS *enc_mb)
void copy_rddata_trellis (Macroblock *currMB, RD_DATA *dest, RD_DATA *src)
void updateMV_mp (Macroblock *currMB, int *m_cost, short ref, int list, int h, int v, int blocktype, int block8x8)
void trellis_coding (Macroblock *currMB, Boolean prev_recode_mb)
void get_dQP_table (Slice *currSlice)

Variables

static const int estErr4x4 [6][4][4]
static const int estErr8x8 [6][8][8]


Detailed Description

Headerfile for trellis based mode decision.

rdoq.h

Author:
Limin Liu <lliu@dolby.com> Alexis Michael Tourapis <alexismt@ieee.org>

Definition in file rdoq.h.


Function Documentation

int est_CAVLC_bits ( ImageParameters p_Img,
int  level_to_enc[16],
int  sign_to_enc[16],
int  nnz,
int  block_type 
)

estimate CAVLC bits

Definition at line 92 of file rdoq_cavlc.c.

References estSyntaxElement_Level_VLC1(), estSyntaxElement_Level_VLCN(), syntaxelement::len, syntaxelement::value1, and syntaxelement::value2.

Referenced by est_RunLevel_CAVLC().

Here is the call graph for this function:

int est_exp_golomb_encode_eq_prob ( unsigned int  symbol  ) 

estimate exp golomb bit cost

Definition at line 257 of file rdoq_cabac.c.

Referenced by est_unary_exp_golomb_level_encode().

void est_RunLevel_CAVLC ( Macroblock currMB,
levelDataStruct *  levelData,
int *  levelTrellis,
int  block_type,
int  b8,
int  b4,
int  coeff_num,
double  lambda 
)

estimate run and level for CAVLC

Definition at line 385 of file rdoq_cavlc.c.

References est_CAVLC_bits(), img_par::nz_coeff, macroblock::p_Img, predict_nnz(), predict_nnz_chroma(), macroblock::subblock_x, and macroblock::subblock_y.

Referenced by rdoq_4x4_CAVLC(), rdoq_8x8_CAVLC(), rdoq_ac4x4_CAVLC(), rdoq_dc_CAVLC(), and rdoq_dc_cr_CAVLC().

Here is the call graph for this function:

int est_write_and_store_CBP_block_bit ( Macroblock currMB,
int  type 
)

estimate CABAC CBP bits

Definition at line 300 of file rdoq_cabac.c.

References get4x4Neighbour(), img_par::mb_data, macroblock::mb_type, macroblock::p_Img, macroblock::p_slice, macroblock::subblock_x, macroblock::subblock_y, and YUV444.

Referenced by rdoq_4x4_CABAC(), rdoq_ac4x4_CABAC(), rdoq_dc_CABAC(), and rdoq_dc_cr_CABAC().

Here is the call graph for this function:

void est_writeRunLevel_CABAC ( Macroblock currMB,
levelDataStruct  levelData[],
int  levelTabMin[],
int  type,
double  lambda,
int  kStart,
int  kStop,
int  noCoeff,
int  estCBP 
)

Rate distortion optimized trellis quantization.

Definition at line 438 of file rdoq_cabac.c.

References est_unary_exp_golomb_level_encode(), macroblock::p_Img, and macroblock::p_slice.

Referenced by rdoq_4x4_CABAC(), rdoq_8x8_CABAC(), rdoq_ac4x4_CABAC(), rdoq_dc_CABAC(), and rdoq_dc_cr_CABAC().

Here is the call graph for this function:

void estRunLevel_CABAC ( Macroblock currMB,
int  context 
)

estimate bit cost for CBP, significant map and significant coefficients

Definition at line 284 of file rdoq_cabac.c.

References est_CBP_block_bit(), est_significance_map(), and est_significant_coefficients().

Here is the call graph for this function:

void init_rdoq_slice ( Slice currSlice  ) 

Initialize the parameters related to RDO_Q in slice level.

Definition at line 33 of file rdoq.c.

Referenced by init_slice().

int init_trellis_data_4x4_CABAC ( Macroblock currMB,
int **  tblock,
int  block_x,
int  qp_per,
int  qp_rem,
LevelQuantParams **  q_params_4x4,
const byte p_scan,
levelDataStruct *  dataLevel,
int *  kStart,
int *  kStop,
int  type 
)

Initialize levelData.

Definition at line 605 of file rdoq_cabac.c.

References macroblock::p_slice.

Referenced by rdoq_4x4_CABAC(), and rdoq_ac4x4_CABAC().

void init_trellis_data_4x4_CAVLC ( Macroblock currMB,
int **  tblock,
int  block_x,
int  qp_per,
int  qp_rem,
LevelQuantParams **  q_params_4x4,
const byte p_scan,
levelDataStruct *  dataLevel,
int  type 
)

Initialize levelData.

Definition at line 482 of file rdoq_cavlc.c.

References macroblock::p_slice.

Referenced by rdoq_4x4_CAVLC(), and rdoq_ac4x4_CAVLC().

void init_trellis_data_8x8_CAVLC ( Macroblock currMB,
int **  tblock,
int  block_x,
int  qp_per,
int  qp_rem,
LevelQuantParams **  q_params_8x8,
const byte p_scan,
levelDataStruct  levelData[4][16] 
)

Initialize levelData.

Definition at line 644 of file rdoq_cavlc.c.

References macroblock::p_slice.

Referenced by rdoq_8x8_CAVLC().

int init_trellis_data_DC_CABAC ( Macroblock currMB,
int **  tblock,
int  qp_per,
int  qp_rem,
LevelQuantParams *  q_params_4x4,
const byte p_scan,
levelDataStruct *  dataLevel,
int *  kStart,
int *  kStop 
)

Initialize levelData for Luma DC.

Definition at line 774 of file rdoq_cabac.c.

References macroblock::p_slice.

Referenced by rdoq_dc_CABAC().

void init_trellis_data_DC_CAVLC ( Macroblock currMB,
int **  tblock,
int  qp_per,
int  qp_rem,
LevelQuantParams *  q_params_4x4,
const byte p_scan,
levelDataStruct *  dataLevel 
)

Initialize levelData for Luma DC.

Definition at line 565 of file rdoq_cavlc.c.

References macroblock::p_slice.

Referenced by rdoq_dc_CAVLC().

int init_trellis_data_DC_cr_CABAC ( Macroblock currMB,
int **  tblock,
int  qp_per,
int  qp_rem,
LevelQuantParams *  q_params_4x4,
const byte p_scan,
levelDataStruct *  dataLevel,
int *  kStart,
int *  kStop 
)

Initialize levelData for Chroma DC.

Definition at line 128 of file rdoq.c.

References macroblock::p_Img, and macroblock::p_slice.

Referenced by rdoq_dc_cr_CABAC().

int init_trellis_data_DC_cr_CAVLC ( Macroblock currMB,
int **  tblock,
int  qp_per,
int  qp_rem,
LevelQuantParams *  q_params_4x4,
const byte p_scan,
levelDataStruct *  dataLevel 
)

Initialize levelData for Chroma DC.

Definition at line 46 of file rdoq.c.

References macroblock::p_Img, and macroblock::p_slice.

Referenced by rdoq_dc_cr_CAVLC().


Documentation generated with DoxyGen