Jump to content
  • Advertisement
Sign in to follow this  
Rob Lemmens

Local Adaptive Thresholding & Noise

This topic is 3324 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Ive implemented a local adaptive thresholder and through some optimizations got it to run very fast on 300DPI input data and it works as expected. Thats the problem as i didnt think about the worst case: I created a test image, 24bpp 300dpi A4, background is white with black text in frames as foreground. I added random noise to the image of a very low intensity difference with the white background. You can barely see it with your eyes. The thressholder however does see it and amplifies the noise. Thats expected, as it scans the local neighbourhood of every pixel for the min/max color values and uses (min+max)/2 + 4 as the value to thresshold the pixel on. The resulting noise can easily be filtered away with a salt n pepper filter modified slightly to also remove single connected pixels (8-way connectedness) as the noise contains a lot of those. The problem with that is that it distorts the endpoints on small features.. like a character. Its difficult to formulate the right question.. removing the noise before thresholding is costly as it is a full color bitmap and the application should be as close to real time as possible. Also removing it completely will be difficult due to the nature of a color image. FFT based denoising is way to costly and doesnt always give a good result.. especially with this noise. I now use a tapered 1d moving average filter followed by a sharpening filter. Its fast and gives reasonable results.. But the best would be to get the thressholder to discard the noise without sacrificing much quality on very light images, how would one go about that? Any idea's || suggestions would be greatly appreciated!

Share this post

Link to post
Share on other sites
Sign in to follow this  

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!