I have a picture like the first one. I want to turn the colorful photo to black and white.So I want to turn all text and table to black and background to white. I used different method like local adaptive threshholding as you can see in the second image, or edge detection. But I am getting a poor result(The quality decrease radically). Do you know any filter which can do this and keep the quality high enough?
Asked
Active
Viewed 2,474 times
2
-
1Possible duplicate of [Extracting text OpenCV](http://stackoverflow.com/questions/23506105/extracting-text-opencv) – Kev1n91 Jan 11 '17 at 12:12
-
Your background in this image in white. As Kev1n91 has stated you only want to extract text. – Jeru Luke Jan 11 '17 at 12:15
-
I do not need bounding box on text area. I just want to turn all information including text and table to black and the rest to white. @kev1n91 – MKH Jan 11 '17 at 12:44
-
assuming your layout won't change from image to image you could use multiple rois with suitable thresholds. – Piglet Jan 11 '17 at 12:45
-
You could use an low threshold (everyting above this threshold gets set to zero) and use it in every channel. White has high values in all channels, while black, grey or red numbers like in your image will either be very low in every channel or just high in one channel – Kev1n91 Jan 11 '17 at 13:49