FFmpeg
|
#include "libavutil/attributes.h"
#include "libavutil/common.h"
#include "cabac_functions.h"
#include "hevc.h"
Go to the source code of this file.
Macros | |
#define | CABAC_MAX_BIN 100 |
#define | CNU 154 |
#define | GET_CABAC(ctx) get_cabac(&s->HEVClc->cc, &s->HEVClc->cabac_state[ctx]) |
#define | LAST_SIG_COEFF(elem) |
#define | GET_COORD(offset, n) |
Variables | |
static const int8_t | num_bins_in_se [] |
number of bin by SyntaxElement. | |
static const int | elem_offset [sizeof(num_bins_in_se)] |
Offset to ctxIdx 0 in init_values and states, indexed by SyntaxElement. | |
static const uint8_t | init_values [3][HEVC_CONTEXTS] |
Indexed by init_type. | |
static const uint8_t | scan_1x1 [1] |
static const uint8_t | horiz_scan2x2_x [4] |
static const uint8_t | horiz_scan2x2_y [4] |
static const uint8_t | horiz_scan4x4_x [16] |
static const uint8_t | horiz_scan4x4_y [16] |
static const uint8_t | horiz_scan8x8_inv [8][8] |
static const uint8_t | diag_scan4x1_x [4] |
static const uint8_t | diag_scan1x4_y [4] |
static const uint8_t | diag_scan2x2_x [4] |
static const uint8_t | diag_scan2x2_y [4] |
static const uint8_t | diag_scan2x2_inv [2][2] |
static const uint8_t | diag_scan8x2_x [16] |
static const uint8_t | diag_scan8x2_y [16] |
static const uint8_t | diag_scan8x2_inv [2][8] |
static const uint8_t | diag_scan2x8_x [16] |
static const uint8_t | diag_scan2x8_y [16] |
static const uint8_t | diag_scan2x8_inv [8][2] |
const uint8_t | ff_hevc_diag_scan4x4_x [16] |
const uint8_t | ff_hevc_diag_scan4x4_y [16] |
static const uint8_t | diag_scan4x4_inv [4][4] |
const uint8_t | ff_hevc_diag_scan8x8_x [64] |
const uint8_t | ff_hevc_diag_scan8x8_y [64] |
static const uint8_t | diag_scan8x8_inv [8][8] |
#define CABAC_MAX_BIN 100 |
Definition at line 30 of file hevc_cabac.c.
Referenced by coeff_abs_level_remaining_decode(), ff_hevc_cu_qp_delta_abs(), and mvd_decode().
#define CNU 154 |
Definition at line 130 of file hevc_cabac.c.
Definition at line 593 of file hevc_cabac.c.
Referenced by abs_mvd_greater0_flag_decode(), abs_mvd_greater1_flag_decode(), coeff_abs_level_greater1_flag_decode(), coeff_abs_level_greater2_flag_decode(), ff_hevc_cbf_cb_cr_decode(), ff_hevc_cbf_luma_decode(), ff_hevc_cu_qp_delta_abs(), ff_hevc_cu_transquant_bypass_flag_decode(), ff_hevc_inter_pred_idc_decode(), ff_hevc_intra_chroma_pred_mode_decode(), ff_hevc_merge_flag_decode(), ff_hevc_merge_idx_decode(), ff_hevc_mvp_lx_flag_decode(), ff_hevc_no_residual_syntax_flag_decode(), ff_hevc_part_mode_decode(), ff_hevc_pred_mode_decode(), ff_hevc_prev_intra_luma_pred_flag_decode(), ff_hevc_ref_idx_lx_decode(), ff_hevc_sao_merge_flag_decode(), ff_hevc_sao_type_idx_decode(), ff_hevc_skip_flag_decode(), ff_hevc_split_coding_unit_flag_decode(), ff_hevc_split_transform_flag_decode(), ff_hevc_transform_skip_flag_decode(), significant_coeff_flag_decode(), and significant_coeff_group_flag_decode().
#define LAST_SIG_COEFF | ( | elem | ) |
Definition at line 900 of file hevc_cabac.c.
Referenced by last_significant_coeff_x_prefix_decode(), and last_significant_coeff_y_prefix_decode().
Referenced by ff_hevc_hls_residual_coding().
void ff_hevc_save_states | ( | HEVCContext * | s, |
int | ctb_addr_ts | ||
) |
Definition at line 498 of file hevc_cabac.c.
Referenced by hls_decode_entry(), and hls_decode_entry_wpp().
|
static |
Definition at line 508 of file hevc_cabac.c.
Referenced by ff_hevc_cabac_init().
|
static |
Definition at line 513 of file hevc_cabac.c.
Referenced by ff_hevc_cabac_init().
|
static |
Definition at line 518 of file hevc_cabac.c.
Referenced by ff_hevc_cabac_init().
|
static |
Definition at line 528 of file hevc_cabac.c.
Referenced by ff_hevc_cabac_init().
void ff_hevc_cabac_init | ( | HEVCContext * | s, |
int | ctb_addr_ts | ||
) |
Definition at line 549 of file hevc_cabac.c.
Referenced by hls_decode_entry(), and hls_decode_entry_wpp().
int ff_hevc_sao_merge_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 595 of file hevc_cabac.c.
Referenced by hls_sao_param().
int ff_hevc_sao_type_idx_decode | ( | HEVCContext * | s | ) |
Definition at line 600 of file hevc_cabac.c.
Referenced by hls_sao_param().
int ff_hevc_sao_band_position_decode | ( | HEVCContext * | s | ) |
Definition at line 610 of file hevc_cabac.c.
Referenced by hls_sao_param().
int ff_hevc_sao_offset_abs_decode | ( | HEVCContext * | s | ) |
Definition at line 620 of file hevc_cabac.c.
Referenced by hls_sao_param().
int ff_hevc_sao_offset_sign_decode | ( | HEVCContext * | s | ) |
Definition at line 630 of file hevc_cabac.c.
Referenced by hls_sao_param().
int ff_hevc_sao_eo_class_decode | ( | HEVCContext * | s | ) |
Definition at line 635 of file hevc_cabac.c.
Referenced by hls_sao_param().
int ff_hevc_end_of_slice_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 642 of file hevc_cabac.c.
Referenced by hls_coding_quadtree().
int ff_hevc_cu_transquant_bypass_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 647 of file hevc_cabac.c.
Referenced by hls_coding_unit().
int ff_hevc_skip_flag_decode | ( | HEVCContext * | s, |
int | x0, | ||
int | y0, | ||
int | x_cb, | ||
int | y_cb | ||
) |
Definition at line 652 of file hevc_cabac.c.
Referenced by hls_coding_unit().
int ff_hevc_cu_qp_delta_abs | ( | HEVCContext * | s | ) |
Definition at line 667 of file hevc_cabac.c.
Referenced by hls_transform_unit().
int ff_hevc_cu_qp_delta_sign_flag | ( | HEVCContext * | s | ) |
Definition at line 692 of file hevc_cabac.c.
Referenced by hls_transform_unit().
int ff_hevc_pred_mode_decode | ( | HEVCContext * | s | ) |
Definition at line 697 of file hevc_cabac.c.
Referenced by hls_coding_unit().
int ff_hevc_split_coding_unit_flag_decode | ( | HEVCContext * | s, |
int | ct_depth, | ||
int | x0, | ||
int | y0 | ||
) |
Definition at line 702 of file hevc_cabac.c.
Referenced by hls_coding_quadtree().
int ff_hevc_part_mode_decode | ( | HEVCContext * | s, |
int | log2_cb_size | ||
) |
Definition at line 721 of file hevc_cabac.c.
Referenced by hls_coding_unit().
int ff_hevc_pcm_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 758 of file hevc_cabac.c.
Referenced by hls_coding_unit().
int ff_hevc_prev_intra_luma_pred_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 763 of file hevc_cabac.c.
Referenced by intra_prediction_unit().
int ff_hevc_mpm_idx_decode | ( | HEVCContext * | s | ) |
Definition at line 768 of file hevc_cabac.c.
Referenced by intra_prediction_unit().
int ff_hevc_rem_intra_luma_pred_mode_decode | ( | HEVCContext * | s | ) |
Definition at line 776 of file hevc_cabac.c.
Referenced by intra_prediction_unit().
int ff_hevc_intra_chroma_pred_mode_decode | ( | HEVCContext * | s | ) |
Definition at line 786 of file hevc_cabac.c.
Referenced by intra_prediction_unit().
int ff_hevc_merge_idx_decode | ( | HEVCContext * | s | ) |
Definition at line 797 of file hevc_cabac.c.
Referenced by hls_prediction_unit().
int ff_hevc_merge_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 808 of file hevc_cabac.c.
Referenced by hls_prediction_unit().
int ff_hevc_inter_pred_idc_decode | ( | HEVCContext * | s, |
int | nPbW, | ||
int | nPbH | ||
) |
Definition at line 813 of file hevc_cabac.c.
Referenced by hls_prediction_unit().
int ff_hevc_ref_idx_lx_decode | ( | HEVCContext * | s, |
int | num_ref_idx_lx | ||
) |
Definition at line 823 of file hevc_cabac.c.
Referenced by hls_prediction_unit().
int ff_hevc_mvp_lx_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 839 of file hevc_cabac.c.
Referenced by hls_prediction_unit().
int ff_hevc_no_residual_syntax_flag_decode | ( | HEVCContext * | s | ) |
Definition at line 844 of file hevc_cabac.c.
Referenced by hls_coding_unit().
|
static |
Definition at line 849 of file hevc_cabac.c.
Referenced by ff_hevc_hls_mvd_coding().
|
static |
Definition at line 854 of file hevc_cabac.c.
Referenced by ff_hevc_hls_mvd_coding().
|
static |
Definition at line 859 of file hevc_cabac.c.
Referenced by ff_hevc_hls_mvd_coding().
|
static |
Definition at line 875 of file hevc_cabac.c.
Referenced by ff_hevc_hls_mvd_coding().
int ff_hevc_split_transform_flag_decode | ( | HEVCContext * | s, |
int | log2_trafo_size | ||
) |
Definition at line 880 of file hevc_cabac.c.
Referenced by hls_transform_tree().
int ff_hevc_cbf_cb_cr_decode | ( | HEVCContext * | s, |
int | trafo_depth | ||
) |
Definition at line 885 of file hevc_cabac.c.
Referenced by hls_transform_tree().
int ff_hevc_cbf_luma_decode | ( | HEVCContext * | s, |
int | trafo_depth | ||
) |
Definition at line 890 of file hevc_cabac.c.
Referenced by hls_transform_tree().
int ff_hevc_transform_skip_flag_decode | ( | HEVCContext * | s, |
int | c_idx | ||
) |
Definition at line 895 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 917 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 923 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 929 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 941 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 950 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 1001 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 1010 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 1018 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 1043 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
void ff_hevc_hls_residual_coding | ( | HEVCContext * | s, |
int | x0, | ||
int | y0, | ||
int | log2_trafo_size, | ||
enum ScanType | scan_idx, | ||
int | c_idx | ||
) |
Definition at line 1053 of file hevc_cabac.c.
Referenced by hls_transform_unit().
void ff_hevc_hls_mvd_coding | ( | HEVCContext * | s, |
int | x0, | ||
int | y0, | ||
int | log2_cb_size | ||
) |
Definition at line 1396 of file hevc_cabac.c.
Referenced by hls_prediction_unit().
|
static |
number of bin by SyntaxElement.
Definition at line 35 of file hevc_cabac.c.
|
static |
Offset to ctxIdx 0 in init_values and states, indexed by SyntaxElement.
Definition at line 84 of file hevc_cabac.c.
Referenced by abs_mvd_greater0_flag_decode(), abs_mvd_greater1_flag_decode(), coeff_abs_level_greater1_flag_decode(), coeff_abs_level_greater2_flag_decode(), ff_hevc_cbf_cb_cr_decode(), ff_hevc_cbf_luma_decode(), ff_hevc_cu_qp_delta_abs(), ff_hevc_cu_transquant_bypass_flag_decode(), ff_hevc_inter_pred_idc_decode(), ff_hevc_intra_chroma_pred_mode_decode(), ff_hevc_merge_flag_decode(), ff_hevc_merge_idx_decode(), ff_hevc_mvp_lx_flag_decode(), ff_hevc_no_residual_syntax_flag_decode(), ff_hevc_part_mode_decode(), ff_hevc_pred_mode_decode(), ff_hevc_prev_intra_luma_pred_flag_decode(), ff_hevc_ref_idx_lx_decode(), ff_hevc_sao_merge_flag_decode(), ff_hevc_sao_type_idx_decode(), ff_hevc_skip_flag_decode(), ff_hevc_split_coding_unit_flag_decode(), ff_hevc_split_transform_flag_decode(), ff_hevc_transform_skip_flag_decode(), significant_coeff_flag_decode(), and significant_coeff_group_flag_decode().
|
static |
Indexed by init_type.
Definition at line 134 of file hevc_cabac.c.
Referenced by cabac_init_state().
|
static |
Definition at line 326 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 330 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 334 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 338 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 345 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 352 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 363 of file hevc_cabac.c.
|
static |
Definition at line 367 of file hevc_cabac.c.
|
static |
Definition at line 371 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 375 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 379 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
|
static |
Definition at line 384 of file hevc_cabac.c.
|
static |
Definition at line 391 of file hevc_cabac.c.
|
static |
Definition at line 398 of file hevc_cabac.c.
|
static |
Definition at line 403 of file hevc_cabac.c.
|
static |
Definition at line 410 of file hevc_cabac.c.
|
static |
Definition at line 417 of file hevc_cabac.c.
const uint8_t ff_hevc_diag_scan4x4_x[16] |
Definition at line 428 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding(), and scaling_list_data().
const uint8_t ff_hevc_diag_scan4x4_y[16] |
Definition at line 435 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding(), and scaling_list_data().
|
static |
Definition at line 442 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().
const uint8_t ff_hevc_diag_scan8x8_x[64] |
Definition at line 449 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding(), and scaling_list_data().
const uint8_t ff_hevc_diag_scan8x8_y[64] |
Definition at line 468 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding(), and scaling_list_data().
|
static |
Definition at line 487 of file hevc_cabac.c.
Referenced by ff_hevc_hls_residual_coding().