Patent ID: 8452083

Claim:
An image processing apparatus comprising: a division unit configured to divide image data, in which a data type of each pixel is represented by color data and attribute data, into blocks each having a size of M×N pixels; a specification unit configured sequentially to determine, as a processing object, each of the blocks divided by said division unit, and to compare data types of respective pixels in the block that is the processing object, thereby specifying a flag indicating a layout pattern of data types included in each of the blocks; a first determination unit configured to determine whether pixels included in a block including two data types to L (L=M×N) data types include a single type of attribute data; and an output unit configured to output, for a block which includes two data types to L data types and for which said first determination unit determines that pixels included in the block include a single type of attribute data, a flag indicating that the block includes a single attribute, a flag indicating a layout pattern of the block, a first type of color data and a first type of attribute data which are extracted from a pixel at a predefined position in the block, and a second type of color data to an Lth type of color data which are extracted based on the layout pattern of the block, to output, for a block which includes two data types to L data types and for which said first determination unit determines that pixels included in the block include more than one type of attribute data, a flag indicating a layout pattern of the block, a first type of color data and a first type of attribute data which are extracted from a pixel at a predefined position in the block, and a second type of color data to an Lth type of color data and a second type of attribute data to an Lth type of attribute data which are extracted based on the layout pattern of the block, and to output, for a block which includes only one data type, a flag indicating a layout pattern of the block, and a first type of color data and a first type of attribute data which are extracted from a pixel at a predefined position in the block.