Click here to Skip to main content
15,884,836 members
Please Sign up or sign in to vote.
5.00/5 (3 votes)
See more:
I have been doing many different stuff in image processing with C# and I know how to do edge detection , Gaussian Blur and many other things but now im stuck with this one...

I have tried different ways to do it and ive gotten close but its not surface blur.

Surface Blur: Blurs an image while preserving edges. This filter is useful for creating special effects and for removing noise or graininess. The Radius option specifies the size of the area sampled for the blur. The Threshold option controls how much the tonal values of neighboring pixels must diverge from the center pixel value before being part of the blur. Pixels with tonal value differences less than the Threshold value are excluded from the blur.
Posted
Comments
Sergey Alexandrovich Kryukov 23-Dec-11 0:08am    
Even though I can intuitively imagine how it's possible, it looks like a very difficult problem to me. My 5 for this question. Using this effect can make a picture looking quite artificial, but the effect itself is very interesting.
--SA
Amir Mahfoozi 24-Dec-11 8:21am    
Is that algorithm different than this : http://notes.ericwillis.com/2009/10/blur-an-image-with-csharp/ ?
BillWoodruff 1-Jan-12 21:44pm    
@Amir: "Is that algorithm different than this ?" Yes ! It does not do edge detection.

1 solution

One wag wrote: "Can't explain it strictly in terms of code. Roughly, Photoshop calculates a 'low pass' of the image, finding the regions of 'flat' color (anything that wouldn't be considered an edge). It multiplies the result of the low pass with a blur (likely Gaussian) and the active selection. It is probably safe to assume that the radius parameter applies to both the low pass and the blur, while the threshold parameter only affects the low pass."[^]

For the technical details (which are far "beyond me"): see:[^].
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900