Patent ID: 8218882

Claim:
An image coding method by which plural code data sets each having a different code amount are generated from one image data set, the method comprising the steps of: setting a different target code amount for each of the code data sets; applying entropy coding processing to the image data set so as to generate plural entropy codes; specifying one of the entropy codes to be truncated so as to control a code amount for each different target code amount; truncating the one of the entropy codes specified in the code amount control step; generating the corresponding code data set; specifying a candidate for the entropy code to be truncated; calculating a code amount of other codes excluding the specified candidate for the entropy code to be truncated; determining whether the calculated code amount calculated in the calculation step and the target code amount satisfy a predetermined relationship; and specifying the candidate for the entropy code to be truncated as an entropy code to be truncated if the calculated code amount and the target code amount satisfy the determined relationship; wherein, if the calculated code amount and the target code amount do not satisfy the predetermined relationship, another candidate for the entropy code to be truncated is added in the order of making a lesser contribution to quality of a decoded image corresponding to the code data set so as to specify the candidate for the entropy code to be truncated, or an entropy code not to be truncated is added in the order of making a greater contribution to the decoded image corresponding to the code data set so as to correct the candidate for the entropy code to be truncated.