Patent ID: RE39984

Claim:
An image encoding apparatus, comprising: generating means for generating a first prediction error difference on the basis of a first value of at least one reference pixel and a first prediction value of the reference pixel, and generating a second prediction error difference on the basis of a second value of an encoding target pixel and a second prediction value of the encoding target pixel, the reference pixel being encoded before the encoding target pixel is encoded and the first prediction error difference being generated before the second prediction error difference is generated; judging means for judging an appearing prediction error difference and an unappearing prediction error difference on the basis of the first prediction error difference, and for encoding the second prediction error difference on the basis of the judged appearing and unappearing prediction error differences, wherein the second prediction error difference is not used in the judging operation; changing means for changing a first corresponding relationship between prediction error difference and encoding data to a second corresponding relationship between prediction error difference and encoding data according to a result obtained by said judging means; and encoding means for encoding the second prediction error difference on the basis of a selected the appearing and unappearing prediction error differences judged by said judging means and one of the first and second corresponding relationships to obtain corresponding encoding data.