gouthaman93
gouthaman93

Reputation: 290

Skin detection and removal in Emgucv

I am new to Image processing. In my application, I want detect and remove skin surrounding an eye.enter image description here

In the above image I want to extract the eye area (and eye brow) without skin.

First, I tried to perform skin detection before removing skin from the image. I used the AdaptiveSkinDetector method in emgu cv, Here is my code

AdaptiveSkinDetector a = new AdaptiveSkinDetector(1, AdaptiveSkinDetector.MorphingMethod.ERODE);
Image<Gray, Byte> skin = new Image<Gray, Byte>(ImageFramecolourrighteye.Width, ImageFramecolourrighteye.Height);

a.Process(ImageFramecolourrighteye, skin);

CvInvoke.cvShowImage("Skin detection", skin);

But the it is not detecting skin. Are there any errors in my code? Is there any better way to perform skin detection? (using colors, perhaps?) References / code sample would be useful.

Your help is highly appreciated

Thanks in advance

Upvotes: 0

Views: 2337

Answers (2)

MoustafaS
MoustafaS

Reputation: 2031

Skin is a very good example proven to be detected well by hue, detect using hue, and play with Saturation and Value until you reach the least nosiy ones, example below, there are many of them. Hue detection will allow you to get skin regardless of its color or brightness.

http://bytefish.de/blog/opencv/skin_color_thresholding/

Upvotes: 0

Dib
Dib

Reputation: 337

Dont know about Emugcv but if your datast is consistent with your example, i think Local binary pattern can be used to detect the contour of the eye (without the skin). You can find detailed explanation here and implementations in here. Even Though the implementations are in matlab hope it helps.

Upvotes: 1

Related Questions