mirror of https://git.ffmpeg.org/ffmpeg.git
avcodec/vvcdec: misc, move pcmf from min_tu_tl_init to min_cb_nz_tl_init
pcmf are cu level flags
This commit is contained in:
parent
634780f3cf
commit
d78b43ecf8
|
@ -1240,16 +1240,18 @@ static void set_cu_tabs(const VVCLocalContext *lc, const CodingUnit *cu)
|
|||
|
||||
set_cb_tab(lc, fc->tab.mmi, pu->mi.motion_model_idc);
|
||||
set_cb_tab(lc, fc->tab.msf, pu->merge_subblock_flag);
|
||||
if (cu->tree_type != DUAL_TREE_CHROMA)
|
||||
if (cu->tree_type != DUAL_TREE_CHROMA) {
|
||||
set_cb_tab(lc, fc->tab.skip, cu->skip_flag);
|
||||
set_cb_tab(lc, fc->tab.pcmf[LUMA], cu->bdpcm_flag[LUMA]);
|
||||
}
|
||||
if (cu->tree_type != DUAL_TREE_LUMA)
|
||||
set_cb_tab(lc, fc->tab.pcmf[CHROMA], cu->bdpcm_flag[CHROMA]);
|
||||
|
||||
while (tu) {
|
||||
for (int j = 0; j < tu->nb_tbs; j++) {
|
||||
const TransformBlock *tb = tu->tbs + j;
|
||||
if (tb->c_idx != LUMA)
|
||||
set_qp_c_tab(lc, tu, tb);
|
||||
if (tb->c_idx != CR && cu->bdpcm_flag[tb->c_idx])
|
||||
set_tb_tab(fc->tab.pcmf[tb->c_idx], 1, fc, tb);
|
||||
}
|
||||
tu = tu->next;
|
||||
}
|
||||
|
|
|
@ -150,6 +150,7 @@ static void min_cb_nz_tl_init(TabList *l, VVCFrameContext *fc)
|
|||
TL_ADD(cb_height[i], pic_size_in_min_cb);
|
||||
TL_ADD(cp_mv[i], pic_size_in_min_cb * MAX_CONTROL_POINTS);
|
||||
TL_ADD(cpm[i], pic_size_in_min_cb);
|
||||
TL_ADD(pcmf[i], pic_size_in_min_cb);
|
||||
}
|
||||
// For luma, qp can only change at the CU level, so the qp tab size is related to the CU.
|
||||
TL_ADD(qp[LUMA], pic_size_in_min_cb);
|
||||
|
@ -189,9 +190,6 @@ static void min_tu_tl_init(TabList *l, VVCFrameContext *fc)
|
|||
|
||||
TL_ADD(tu_joint_cbcr_residual_flag, pic_size_in_min_tu);
|
||||
|
||||
for (int i = LUMA; i <= CHROMA; i++)
|
||||
TL_ADD(pcmf[i], pic_size_in_min_tu);
|
||||
|
||||
for (int i = 0; i < VVC_MAX_SAMPLE_ARRAYS; i++) {
|
||||
TL_ADD(tu_coded_flag[i], pic_size_in_min_tu);
|
||||
|
||||
|
|
|
@ -543,9 +543,9 @@ static av_always_inline int deblock_bs(const VVCLocalContext *lc,
|
|||
const uint8_t chroma = !!c_idx;
|
||||
const int tu_p = (y_p >> log2_min_tu_size) * min_tu_width + (x_p >> log2_min_tu_size);
|
||||
const int tu_q = (y_q >> log2_min_tu_size) * min_tu_width + (x_q >> log2_min_tu_size);
|
||||
const uint8_t pcmf = fc->tab.pcmf[chroma][tu_p] && fc->tab.pcmf[chroma][tu_q];
|
||||
const int cb_p = (y_p >> log2_min_cb_size) * min_cb_width + (x_p >> log2_min_cb_size);
|
||||
const int cb_q = (y_q >> log2_min_cb_size) * min_cb_width + (x_q >> log2_min_cb_size);
|
||||
const uint8_t pcmf = fc->tab.pcmf[chroma][cb_p] && fc->tab.pcmf[chroma][cb_q];
|
||||
const uint8_t intra = fc->tab.cpm[chroma][cb_p] == MODE_INTRA || fc->tab.cpm[chroma][cb_q] == MODE_INTRA;
|
||||
const uint8_t same_mode = fc->tab.cpm[chroma][cb_p] == fc->tab.cpm[chroma][cb_q];
|
||||
|
||||
|
|
Loading…
Reference in New Issue