Patent ID: 8817346

Claim:
An image processing apparatus comprising: a first storage unit that stores therein a plurality of code data each of which is formed by arranging an identification code at a head side of line code data and a line end code at an end side of the line code data obtained by coding image data in a line unit, in order from a first line to a last line of the image data, the identification code being arranged at a head side of each line of a plurality of lines of the code data, the line end code being arranged at an end side of each line of the plurality of lines of the code data, and the line end code being independent of an amount of code of each respective line of the plurality of lines; a first reading unit that reads the code data from the first storage unit; a second storage unit that recognizes the identification code from the code data read by the first reading unit to store therein the code data in a line unit based on the identification code; a second reading unit that reads the code data from the second storage unit; a decoding unit that decodes the code data read by the second reading unit; a third storage unit that stores therein decoded image data obtained by decoding the code data by the decoding unit in a line unit; and a third reading unit that reads the decoded image data stored in the third storage unit in a line unit, wherein, when the image data is rotated 180 degrees and is output, the first reading unit reads the code data from the first storage unit from the last line to the first line and reads each line from an end to a head of the line, the second reading unit reads the code data from the second storage unit from a position of the identification code included in the code data to the end of the line with respect to the code data, and the third reading unit reads the decoded image data from the third storage unit from the end to the head of the line in a pixel unit.