Patent ID: 7221483

Claim:
An image encoding method for encoding image data using a block consisting of plural pixels as a unit of processing, said image encoding method comprising the steps of: extracting statistical information for each pixel value, from a plurality of encoded blocks adjacent to an encoding target block, at each corresponding position in said respective blocks; and performing encoding processing on said encoding target block using the extracted statistical information, wherein the encoding step comprises the steps of: selecting a reference pixel for each pixel within said encoding target block from said encoding target block and a plurality of adjacent blocks whose encoding order is earlier than said target block, based on the extracted statistical information, predicting a value of each pixel within said encoding target block from the selected reference pixels, and performing entropy encoding on an error between the value of each pixel within said encoding target block and its predicted value; and wherein the selecting step comprises the step of: selecting a pixel as a reference pixel from said encoding target block and a plurality of adjacent blocks whose encoding order is earlier than said target block, said pixel placed at a position within a block having a value of statistical information such that a difference between this value and a value of statistical information for the position of an encoding target pixel within said encoding target block is within a specified range, and said pixel whose encoding order is earlier than said encoding target pixel.