The present invention aims to prevent a problem that an image on a
document sheet is erased due to misdetection of a line-shaped noise. A
copy machine 1 compares RGB values of a target pixel with averaged RGB
values (Step S103). If only one of the RGB values has a difference that
is greater than a prescribed value Ref2 (Step S103: YES), the copy
machine 1 extracts the target pixel as a line-shaped noise pixel, and
moves to a line-shaped noise correction (Step S108) while holding the
address of the target pixel in a line-shaped noise address storing area
49b. If two of the RGB values have differences (Step S103: NO, Step S104:
YES) and a difference between these two of the RGB values is no greater
than a prescribed value Ref3 (Step S105: YES), the copy machine 1
extracts the target pixel as a line-shaped noise pixel, and moves to the
line-shaped noise correction (Step S108) while holding the address of the
target pixel in the line-shaped noise address storing area 49b.