﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
312	Redundant cbf_cb and cbf_cr flags when log2MaxTrafoSize is set to two	zhyang		"There are three redundant cbf_cb and cbf_cr flags for each 4x4 chroma TU when log2MaxTrafoSize is set to two. 

When log2MaxTrafoSize is set to two, there are only 4x4 luma TUs and 4x4 chroma TUs and every four luma TUs correspond to one cb TU and one cr TU. So only one set of cbf_cb and cbf_cr flags should be coded corresponding to every four cbf_luma flags. 

However, HM 5.1 software still codes one cbf_cb and cbf_cr flags corresponding to each cbf_luma when log2MaxTrafoSize is set to two, which causes three redundant cbf_cb and cbf_cr flags for each 4x4 chroma TU. 

The relevant code causing this behavior is in TDecEntropy::xDecodeTransformSubdiv
{{{
Bool bFirstCbfOfCU = uiLog2TrafoSize == pcCU->getSlice()->getSPS()->getQuadtreeTULog2MaxSize() || uiTrDepth == 0
}}}

It does not consider the case when log2MaxTrafoSize is set to two.  So for each 4x4 luma TU, bFirstCbfOfCU is always true and there will always be a set of cbf_cb and cbf_cr coded. 

"	defect	closed	minor	HM-16.3	HM	HM-5.1	fixed		fbossen ksuehring davidf jct-vc@…
