PURPOSE: To make the error correction effcient, by producing an ECC code stored in an ECC memory from specified image sub-arrangement not duplicated with equal intervals.
CONSTITUTION: A data is read out from a memory 7 in the mode of (1×pq) of lateral one row with equal intervals, for example, and this is written in a memory area 9 with one longitudinal column mode, (pq×1) by rotating the data by 90° via an intermediate buffer 8. On the other hand, the data is read out in a rectangular (p×q) mode from a memory 7', turned by 90° via an intermediate buffer 8' and written in a memory area 9'. In this case, in adding the ECC to the data of memory, the ECC is generated by splitting the memory area with the correspondence to the access type as one lateral row of (1×pq) mode, one longitudinal column of (pq×1) mode, or a rectangular p×q mode. Since it is possible to take the intermediate buffers 8 and 8' as required larger, the buffers can be designated as the 2nd specified address.