Patent ID: 8005146

Claim:
A coding method for arithmetic coding, on a block basis, coefficients of frequency components which are generated by frequency transformation performed on picture data of a block which has a predetermined size of pixels, the coding method comprising: a coefficients scanning step of scanning the coefficients of a block in a predetermined scanning order starting at a high frequency component toward a low frequency component; a converting step of converting each absolute value of the coefficients into binary data; an arithmetic coding step of performing arithmetic coding on a first bit of the binary data corresponding to each absolute value of the coefficients according to the predetermined scanning order by using a plurality of probability tables; and a switching step of switching between the plurality of probability tables, from a current probability table for the first bit of the binary data corresponding to a first coefficient to be coded, to a new probability table for the first bit of the binary data corresponding to a second coefficient to be coded, based on a result of a comparison between an absolute value of the first coefficient to be coded and a predetermined threshold value, wherein, in the switching step, the switching between the plurality of probability tables is performed in a predetermined one direction within each block such that each of the probability tables, which has been used for performing arithmetic coding on the first bit of the binary data corresponding to an already coded coefficient before switching to the new probability table, is not used within each block after switching to the new probability table, and the switching is not performed in the direction opposite to the predetermined one direction regardless of said result of the comparison, and wherein, within each block, if a predetermined one of the plurality of probability tables has been used to perform arithmetic coding, the switching between the plurality of probability tables is not performed regardless of said result of the comparison.