Reputation: 5183
I have a Bitmap (in C#) which contains a silhouette of a single person on a transparent background. The silhouette is a particular hue or color, but of varying intensities.
I'm trying to figure out how smooth the edges of the silhouette, and if possible remove artifacts that are not part of the silhouette. The goal is to get a nice smooth (not blurred) representation of the person, as un-pixelated and artifact free as possible.
Can anyone suggest an approach (I'm working in C# .NET 4.0) to accomplish this? I was thinking some sort of 3 pass approach- edge detection, outlier or artifact removal and then smoothing, but I have never done this kind of thing before.
Thanks!
Upvotes: 0
Views: 3488
Reputation: 4900
You can create an edge detection algorith. It depends on how good your pictures are, the result will be available quickly.
After edge detection you can try to create the polygon around the detected border. The polygon has maximum resolution to use any calculated opacity mask. If your images are in good resolution without a lot of noises (like objects or hair) it should be a cool work.
Perhaps this project helps you for your project: http://www.codeproject.com/Articles/9727/Image-Processing-Lab-in-C
Regards
Upvotes: 1