views:

44

answers:

1

I have an image region how can I know whether its surface is smooth or not

+4  A: 

What you have here is an ill-posed problem. There probably is no right answer, it depends on the objectives you've set to achieve by solving the problem itself. So, tell us more about what this smoothness means to you, what do you want to use it for? What do you have to do with the smooth versus the non-smooth image regions?

In the mean time, I'll tell you that one way to do it would be to compute a measure of deviation of each pixel's color from the colors of its neighbors. You pick a 3x3, 5x5 or larger neighborhood around each pixel, depending on the degree of locality that you're interested in for your smoothness calculation and calculate, say, the sum of all the differences between the current pixel's color and each of the neighboring pixels' colors, or the sum of all the differences between the current pixel's color and the average color of the vicinity. The bigger values mean less local smoothness. Neighborhoods with similar values may be aggregated to obtain bigger regions, giving a smoothness-based image segmentation.

luvieere