mirror of
https://github.com/ultravideo/uvg266.git
synced 2024-11-27 11:24:05 +00:00
[dual-tree] [lfnst] allow counting lfnst bits for chroma in dual-tree
This commit is contained in:
parent
37590add20
commit
d16d6e3dd8
|
@ -2186,7 +2186,8 @@ void uvg_cu_cost_inter_rd2(encoder_state_t * const state,
|
|||
v_pred,
|
||||
u_resi,
|
||||
v_resi,
|
||||
&chorma_ts_out);
|
||||
&chorma_ts_out,
|
||||
UVG_BOTH_T);
|
||||
cbf_clear(&cur_cu->cbf, depth, COLOR_U);
|
||||
cbf_clear(&cur_cu->cbf, depth, COLOR_V);
|
||||
if (chorma_ts_out.best_u_cost + chorma_ts_out.best_v_cost < chorma_ts_out.best_combined_cost) {
|
||||
|
|
|
@ -1532,7 +1532,8 @@ int8_t uvg_search_intra_chroma_rdo(
|
|||
v_pred,
|
||||
u_resi,
|
||||
v_resi,
|
||||
&chorma_ts_out);
|
||||
&chorma_ts_out,
|
||||
tree_type);
|
||||
|
||||
// LFNST constraint failed
|
||||
if(chorma_ts_out.best_u_index == -1 && chorma_ts_out.best_combined_index == -1) {
|
||||
|
|
|
@ -482,7 +482,8 @@ void uvg_chroma_transform_search(
|
|||
uvg_pixel v_pred[1024],
|
||||
int16_t u_resi[1024],
|
||||
int16_t v_resi[1024],
|
||||
uvg_chorma_ts_out_t* chorma_ts_out)
|
||||
uvg_chorma_ts_out_t* chorma_ts_out,
|
||||
enum uvg_tree_type tree_type)
|
||||
{
|
||||
ALIGNED(64) coeff_t u_coeff[LCU_WIDTH_C * LCU_WIDTH_C * 5];
|
||||
ALIGNED(64) uint8_t u_recon[LCU_WIDTH_C * LCU_WIDTH_C * 5];
|
||||
|
@ -699,7 +700,7 @@ void uvg_chroma_transform_search(
|
|||
scan_order,
|
||||
transforms[i] == CHROMA_TS);
|
||||
}
|
||||
if(depth == 4 && state->encoder_control->cfg.lfnst && 0) {
|
||||
if((depth == 4 || tree_type == UVG_CHROMA_T) && state->encoder_control->cfg.lfnst && 0) {
|
||||
if(uvg_is_lfnst_allowed(state, pred_cu, width, height, 0, 0 , UVG_CHROMA_T)) {
|
||||
const int lfnst_idx = pred_cu->cr_lfnst_idx;
|
||||
CABAC_FBITS_UPDATE(
|
||||
|
|
|
@ -110,7 +110,8 @@ void uvg_chroma_transform_search(
|
|||
uvg_pixel v_pred[1024],
|
||||
int16_t u_resi[1024],
|
||||
int16_t v_resi[1024],
|
||||
uvg_chorma_ts_out_t* chorma_ts_out);
|
||||
uvg_chorma_ts_out_t* chorma_ts_out,
|
||||
enum uvg_tree_type tree_type);
|
||||
|
||||
enum uvg_chroma_transforms {
|
||||
DCT7_CHROMA = 0,
|
||||
|
|
Loading…
Reference in a new issue