Jump to content


Photo

Bilateral filter - edge preserving noise reduction and blur


  • Please log in to reply
4 replies to this topic

#1 smax

smax
  • Newbies
  • 2 posts
  • Reputation:0

Posted 10 February 2012 - 09:45 AM

Download the plug-in and find installation instructions on the Codeplex project page.

Details on how the filter works, parameters and resulting images can be found in this blog post.

Bilateral filter seems to be a very underestimated image improving technique. It's not frequently met across internet. The filter may help with solving the following tasks:
  • Noise reduction - pretty utilitarian & usual goal. When you have photos pictured with high ISO or within poor lighting conditions noise reduction will give them a more natural look
  • Sharpen edges
  • Great artistic effects - my favorite part, images processed with bilateral filter get an appealing glossy look


Posted ImagePosted Image

Edited by smax, 10 February 2012 - 09:45 AM.


#2 Rick Brewster

Rick Brewster

    Paint.NET Author and Developer

  • Administrators
  • 12,611 posts
  • LocationKirkland, WA
  • Reputation:125

Posted 10 February 2012 - 09:55 PM

How does this compare with Reduce Noise and Surface Blur?
The Paint.NET Blog: http://blog.getpaint.net/
Donations are always appreciated! http://www.getpaint.net/donate.html

Posted Image

#3 smax

smax
  • Newbies
  • 2 posts
  • Reputation:0

Posted 11 February 2012 - 01:18 PM

Apparently Bilateral filter may produce similar results as Noise reduction or Surface blur effects. It's hard to draw direct comparison (I'm not aware of internal implemetation details of standard effects) but I may present my subjective comparison of images produced.

The first important thing is that Bilateral filter has 3 parameters (rather than 2 in case of standard effects):

  • Kernel size - this can be treated as radius, it defines how many surrounding pixels take part in calculations for each specific pixel. Greater value is required for High-Res images.
  • Color factor - this one can be treated as color tolerance, the greater the values is the larger would be areas blurred and more pixels would be grouped
  • Spatial factor - this one defines how strong is blur within areas (domains) of similar colors
Normally a combination of great spatial factor and small color factor is used to achieve noise reduction; large values for both parameters are for fancy blurry effects.

The bellow example shows difference in noise reduction. I’ve tried to achieve similar looking results for both Bilateral and Noise reduction effects by playing with parameters.

Original:


Posted Image

Bilateral - left, Noise reduction(10, 0.80) - right:

Posted ImagePosted Image

Noise reduction effect changes luminosity (shaded passenger side of the car), Bilateral filter preserves more details (trees in the background) and in my opinion noise is higher on the second image (far lanterns, bonnet).

If we try to achieve blurry effect the difference is more distinctive.

Original:

Posted Image

Bilateral(15, 60, 100):

Posted Image

Surface blur(20, 50):

Posted Image

As you can see there're differences in the resulting images and the filter can be treated as an alternative to both standar Noise reduction and Surface blur effects.

#4 Ed Harvey

Ed Harvey
  • Members
  • 428 posts
  • LocationSydney, Australia
  • Reputation:8

Posted 12 February 2012 - 03:51 PM

Apparently Bilateral filter may produce similar results as Noise reduction or Surface blur effects. It's hard to draw direct comparison (I'm not aware of internal implemetation details of standard effects) but I may present my subjective comparison of images produced.

Paint.Net's Surface Blur is, in fact, a variant of the classic bilateral filter.

It just uses different range functions, which (with an algorithmic sleight of hand) allow it to be calculated in roughly O(n) rather than O(n²) :)
Posted Image

#5 Rick Brewster

Rick Brewster

    Paint.NET Author and Developer

  • Administrators
  • 12,611 posts
  • LocationKirkland, WA
  • Reputation:125

Posted 28 February 2012 - 06:49 PM

Good choice of cars, btw.
The Paint.NET Blog: http://blog.getpaint.net/
Donations are always appreciated! http://www.getpaint.net/donate.html

Posted Image