Image processing apparatus and image processing method
An image inputter and a controller are provided, and the controller acquires a multiple-value image via the image inputter, acquires a first image obtained by performing a correction process and a simple binarization process on the multiple-value image and a second image obtained by performing the correction process on the multiple-value image, uses a difference value of a pixel value of the second image with respect to the first image on a pixel-by-pixel basis to determine whether a jaggy occurs when the multiple-value image is output as a simple binary image, when a jaggy occurs, determines a conversion method for converting the multiple-value image in accordance with an amount of statistics calculated using the difference value, and outputs an image obtained by conversion using the determined conversion method.
1 . An image processing apparatus comprising an image inputter and a controller, wherein
the controller
acquires a multiple-value image having a plurality of gradation values via the image inputter,
acquires a first image by performing a correction process and a simple binarization process on the multiple-value image and a second image by performing the correction process on the multiple-value image,
uses a difference value of a pixel value of the second image with respect to the first image on a pixel-by-pixel basis to determine whether a jaggy occurs when the multiple-value image is output as a simple binary image,
when the jaggy occurs, determines a conversion method for converting the multiple-value image in accordance with a statistical amount calculated using an entropy value of the difference value, and
outputs an image obtained by conversion using the determined conversion method,
wherein the conversion method comprises one of a first conversion method for converting the multiple-value image to grayscale, a second conversion method for performing an error diffusion process on the multiple-value image to convert the multiple-value image into a binary image, and a third conversion method for converting the multiple-value image in gray small-number colors.
2 . The image processing apparatus according to claim 1 , wherein the controller determines the conversion method for converting the multiple-value image based on a range of the entropy value of the difference value.
3 . The image processing apparatus according to claim 2 , wherein
the multiple-value image is selectively output with priority on file size or image quality,
when the multiple-value image is output with priority on the image quality, the controller determines that a priority order for determining the conversion method for converting the multiple-value image is the following order; the first conversion method, the second conversion method, and then the third conversion method, and
when the multiple-value image is output with priority on the file size, the controller determines that the priority order for determining the conversion method for converting the multiple-value image is the following order; the third conversion method, the second conversion method, and then the first conversion method.
4 . The image processing apparatus according to claim 1 , wherein the correction process includes at least a process to correct contrast of the multiple-value image.
5 . The image processing apparatus according to claim 4 , wherein the first image is obtained by performing
as the correction process, a sharpening process on the multiple-value image and then a process to correct contrast of the multiple-value image, and
a simple binarization process after the correction process.
6 . The image processing apparatus according to claim 1 , wherein the controller detects occurrence of the jaggy by using only pixels included in a character region of the multiple-value image.
7 . The image processing apparatus according to claim 6 , wherein the controller determines that the jaggy occurs when a number of blocks is equal to or more than a third threshold, in which a number of candidate pixels, which are pixels having the difference values equal to or more than a first threshold, in units of blocks of the multiple-value image is equal to or more than a second threshold.
8 . An image processing method comprising:
acquiring a first image by performing a correction process and a simple binarization process on a multiple-value image having a plurality of gradation values and a second image by performing the correction process on the multiple-value image and using a difference value of a pixel value of the second image with respect to the first image on a pixel-by-pixel basis to determine whether a jaggy occurs when the multiple-value image is output as a simple binary image,
when the jaggy occurs, determining a conversion method for converting the multiple-value image in accordance with a statistical amount calculated using an entropy value of the difference value, and
outputting an image obtained by conversion using the determined conversion method, wherein
the conversion method comprises one of a first conversion method for converting the multiple-value image to grayscale, a second conversion method for performing an error diffusion process on the multiple-value image to convert the multiple-value image into a binary image, and a third conversion method for converting the multiple-value image in gray small-number colors.
9 . The image processing method according to claim 8 , further comprising determining the conversion method for converting the multiple-value image based on a range of the entropy value of the difference value.
10 . The image processing method according to claim 9 , further comprising:
selectively outputting the multiple-value image with priority on file size or image quality,
when the multiple-value image is output with priority on the image quality, determining that a priority order for determining the conversion method for converting the multiple-value image is the following order; the first conversion method, the second conversion method, and then the third conversion method, and
when the multiple-value image is output with priority on the file size, determining that the priority order for determining the conversion method for converting the multiple-value image is the following order; the third conversion method, the second conversion method, and then the first conversion method.
11 . The image processing method according to claim 8 , wherein the correction process includes at least a process to correct contrast of the multiple-value image.
12 . The image processing method according to claim 11 , wherein the first image is obtained by performing
as the correction process, a sharpening process on the multiple-value image and then a process to correct contrast of the multiple-value image, and
a simple binarization process after the correction process.
13 . The image processing method according to claim 8 , further comprising detecting occurrence of the jaggy by using only pixels included in a character region of the multiple-value image.
14 . The image processing method according to claim 13 , further comprising determining that the jaggy occurs when a number of blocks is equal to or more than a third threshold, in which a number of candidate pixels, which are pixels having the difference values equal to or more than a first threshold, in units of blocks of the multiple-value image is equal to or more than a second threshold.