There is provided means for setting the RST insertion position comprising a
restart line interval setting register 13 automatically setting the insertion
position of the RST to the head of the scanning line with the least correlation
between two image data for each of the interval L of the arbitrarily set scanning
line and a restart interval calculation portion 5. With this structure,
a reduction in the compression rate on the basis of the insertion of the RST can
be avoided and a high compression rate can be attained.