A method of reconstructing significant-coefficient flags for a transform unit from a bitstream of encoded data, the bitstream including encoded significant-coefficient-group flags, wherein each significant-coefficient-group flag corresponds to a respective group of significant-coefficient flags, the method comprising: for each of the respective groups of significant-coefficient flags, in a group reverse scan order, the group reverse scan order starting with the group containing the significant-coefficient flag for a last-significant coefficient indicating the location of the last non-zero significant coefficient in the transform unit, and working back through the groups in reverse direction until the group containing the DC position in the transform unit is reached, setting the group's significant-coefficient-group flag to be 1 if that group either contains the significant-coefficient flag for the last-significant coefficient or contains the significant-coefficient flag for a coefficient at the DC position in the transform unit, and otherwise decoding the significant-coefficient-group flag for that group from the bitstream of encoded data, and - if the group's significant-coefficient-group flag is 1, reconstructing the significant-coefficient flags in a reverse scan order within that group by: inferring, without decoding from the bitstream, the significant-coefficient-flag at position (0,0) in that group to be 1 if the significant-coefficient-group flag is decoded to be non-zero and if all of the previous significant-coefficient flags in that group are zero, and otherwise decoding the significant-coefficient flag from the bitstream; and - if the significant-coefficient-group flag is zero, then setting all the significant-coefficient flags in the group to zero. for each of the respective groups of significant-coefficient flags, in a group reverse scan order, the group reverse scan order starting with the group containing the significant-coefficient flag for a last-significant coefficient indicating the location of the last non-zero significant coefficient in the transform unit, and working back through the groups in reverse direction until the group containing the DC position in the transform unit is reached, setting the group's significant-coefficient-group flag to be 1 if that group either contains the significant-coefficient flag for the last-significant coefficient or contains the significant-coefficient flag for a coefficient at the DC position in the transform unit, and otherwise decoding the significant-coefficient-group flag for that group from the bitstream of encoded data, and - if the group's significant-coefficient-group flag is 1, reconstructing the significant-coefficient flags in a reverse scan order within that group by: inferring, without decoding from the bitstream, the significant-coefficient-flag at position (0,0) in that group to be 1 if the significant-coefficient-group flag is decoded to be non-zero and if all of the previous significant-coefficient flags in that group are zero, and otherwise decoding the significant-coefficient flag from the bitstream; and - if the significant-coefficient-group flag is zero, then setting all the significant-coefficient flags in the group to zero. - if the group's significant-coefficient-group flag is 1, reconstructing the significant-coefficient flags in a reverse scan order within that group by: inferring, without decoding from the bitstream, the significant-coefficient-flag at position (0,0) in that group to be 1 if the significant-coefficient-group flag is decoded to be non-zero and if all of the previous significant-coefficient flags in that group are zero, and otherwise decoding the significant-coefficient flag from the bitstream; and inferring, without decoding from the bitstream, the significant-coefficient-flag at position (0,0) in that group to be 1 if the significant-coefficient-group flag is decoded to be non-zero and if all of the previous significant-coefficient flags in that group are zero, and otherwise decoding the significant-coefficient flag from the bitstream; and - if the significant-coefficient-group flag is zero, then setting all the significant-coefficient flags in the group to zero.