Image Processing Reference
In-Depth Information
separately. This improvement made by Highlight image filter (and Smart Contrast as well)
regarding the way contrast is increased produces even more contrast between the text in an
image and the background in cases when this is needed such as when the color of the text is
close to the color of the background making the text more visible than it would be by simply
applying Contrast filter.
2 Description of smart contrast image filter
Smart Contrast filter compares the value of each component (e.g., Red) of each pixel with
127 (255/2, note that the range in which the components Red, Green, and Blue vary is 0-255
when it comes to RGB images as in this case) and if the value is less than 127, it performs
a certain transformation to that specific component, if greater it performs a different trans-
formation. As a case study, if an image that contains some text is considered and the color
of the text would be (R t ,G t ,B t ) = (126,126,125) and the color of the background would be
(R b ,G b ,B b ) = (130,137,136), then the colors would be prety similar, so the text would be hard to
recognize even for the human eye. In this case, which may often occurs, Smart Contrast filter
decreases more the color of the text and increases more the color of the background than Con-
trast filter would do, making the text more visible and more easily to be detected by OCR.
Thus, Smart Contrast keeps the good work Contrast filter does and, in addition, produces
good results for edge cases.
2.1 Contrast Image Filter
Contrast filter is based on the transformation in Equations (1a) - (1c) where contrast is the con-
trast scale (the degree to which the contrast is increased) and red, green, and blue are the val-
ues of the components of a pixel:
(1a)
(1b)
(1c)
 
 
Search WWH ::




Custom Search