12) 9.2.3 Parsing process for run information Inputs to this process are bits from slice data, the number of non-zero transform coefficient levels TotalCoeff( coeff_token), and the maximum number of non-zero transform coefficient levels maxNumCoeff. Output of this process is a list of runs of zero transform coefficient levels preceding non-zero transform coefficient levels called runVal. Initially, an index i is set equal to 0. The variable zerosLeft is derived as follows: If the number of non-zero transform coefficient levels TotalCoeff( coeff_token ) is equal to the maximum number of non-zero transform coefficient levels maxNumCoeff, a variable zerosLeft is set equal to 0. Otherwise (the number of non-zero transform coefficient levels TotalCoeff( coeff_token ) is less than the maximum number of non-zero transform coefficient levels maxNumCoeff), total_zeros is decoded and zerosLeft is set equal to its value. The variable tzVlcIndex is set equal to TotalCoeff( coeff_token). The VLC used to decode total_zeros is derived as follows: If maxNumCoeff is equal to 4, one of the VLCs specified in Table 9-9 (a) is used. Otherwise, if maxNumCoeff is equal to 8, one of the VLCs specified in Table 9-9 (b) is used. Otherwise (maxNumCoeff is not equal to 4 and not equal to 8), VLCs from Tables 9-7 and 9-8 are used. The following ordered steps are then performed TotalCoeff( coeff_token) - 1 times: 1. The variable run Val[ i ] is derived as follows: If zerosLeft is greater than zero, a value run_before is decoded based on Table 9-10 and zerosLeft. runVal[ i ] is set equal to run_before. - Otherwise (zerosLeft is equal to 0), run Val[ i ] is set equal to 0. The value of runVal[ i ] is subtracted from zerosLeft and the result is assigned to zerosLeft. It is a requirement of bitstream conformance that the result of the subtraction shall be greater than or equal to 0. 3. The index i is incremented by 1. Finally the value of zerosLeft is assigned to run Val[ i]. Rec. ITU-T H.264 (01/2012) Table 9-7 - total_zeros tables for 4x4 block