id summary reporter owner description type status priority milestone component version resolution keywords cc 687 P1034 - Wrap around in scaling list coding bheng "For scaling list coding, there seems to be a wraparound process missing for the nextCoef derivation. Specifically, the nextCoef is an accumulation of delta values, which could be as small as -128 each time: nextCoef += scaling_list_delta_coef[ id ][ i ] There is no wrapping process here, so after accumulating a few coefficients, nextCoef could be a very large negative number. ScalingList[id][i] is just set equal to nextCoef. ScalingList[ id ][ i ] = nextCoef The value of ScalingList[id][i] is added to the predicted value and modulo wrapped: ScalingMatrixRec[ id ][ x ][ y ] = ( ScalingMatrixPred[ x ][ y ] + ScalingList[ id ][ k ] + 256 ) % 256 ) (7-72) The wrapping used here assumes that the (ScalingMatrixPred + ScalingList) sum is no smaller than -256. However, as shown above, ScalingList could be a very large negative value. That would require a modulo of a negative number, which is undefined in the spec. For example, the sequence of coefficients [144, 16, 144, 16, 144, 16, ... ] in scan order, requires all scaling_list_delta_coef = -128. It's impossible to code this sequence without either creating a negative modulo situation above, or coding delta values outside the legal range [-128,127] (like VTM does). Assuming it was not intended to make certain patterns of scaling lists impossible to encode, I believe the nextCoeff value should be wrapped to stay within [-128,127]. Also, there seems to be a left parenthesis missing in equation (7-72) above. " defect closed minor spec VVC D7 vE fixed ksuehring bbross XiangLi fbossen jvet@…