Skip to main content
Tweeted twitter.com/#!/StackSignals/status/212040371293782016
edited title
Link
Roney Island
  • 453
  • 1
  • 4
  • 13

OpenCV detectin skin colour invariant with illumination changes

added 88 characters in body
Source Link
Roney Island
  • 453
  • 1
  • 4
  • 13

I have to capture skin colour independent of illumination. I used the following criteria(using hsv and rgb) but it ain't working:

int h = get_hue(...);
int s = get_saturation(...);
int r = get_red_component(...);
int g = get_green_component(...);
int b = get_blue_component(...);

if ((h<38)&&(h>6)&&(s>0.23)&&(s<0.68)){
    // skin color
}
else if ((r>95) && (g>40) && (b>20) && 
         ((maximum(r,g,b)-minimum(r,g,b))>15) && 
         (abs(r-g)>15)&&(r>g)&&(r>b)){
   // also skin color
}

It works in the morning when my skin is illuminated but by evening it does not work.

Any Help will be appreciated. Thanks in Advance. (PS -my skin ain't white.)

I have to capture skin colour independent of illumination. I used the following criteria(using hsv and rgb) but it ain't working:

int h = get_hue(...);
int s = get_saturation(...);
int r = get_red_component(...);
int g = get_green_component(...);
int b = get_blue_component(...);

if ((h<38)&&(h>6)&&(s>0.23)&&(s<0.68)){
    // skin color
}
else if ((r>95) && (g>40) && (b>20) && 
         ((maximum(r,g,b)-minimum(r,g,b))>15) && 
         (abs(r-g)>15)&&(r>g)&&(r>b)){
   // also skin color
}

Any Help will be appreciated. Thanks in Advance. (PS -my skin ain't white.)

I have to capture skin colour independent of illumination. I used the following criteria(using hsv and rgb) but it ain't working:

int h = get_hue(...);
int s = get_saturation(...);
int r = get_red_component(...);
int g = get_green_component(...);
int b = get_blue_component(...);

if ((h<38)&&(h>6)&&(s>0.23)&&(s<0.68)){
    // skin color
}
else if ((r>95) && (g>40) && (b>20) && 
         ((maximum(r,g,b)-minimum(r,g,b))>15) && 
         (abs(r-g)>15)&&(r>g)&&(r>b)){
   // also skin color
}

It works in the morning when my skin is illuminated but by evening it does not work.

Any Help will be appreciated. Thanks in Advance. (PS -my skin ain't white.)

improved code formatting for more readability, added image-processing tag
Source Link

I have to capture skin colour independent of illumination. iI used the following criteria(using hsv and rgb) but it ain't working.:

  1. if((h<38)&&(h>6)&&(s>.23)&&(s<.68)){then skin clolour}
  2. else if((r>95)&&(g>40)&&(b>20)&&((maximum(r,g,b)-minimum(r,g,b))>15)&&(abs(r-g)>15)&&(r>g)&&(r>b)){then also skin colour}
int h = get_hue(...);
int s = get_saturation(...);
int r = get_red_component(...);
int g = get_green_component(...);
int b = get_blue_component(...);

if ((h<38)&&(h>6)&&(s>0.23)&&(s<0.68)){
    // skin color
}
else if ((r>95) && (g>40) && (b>20) && 
         ((maximum(r,g,b)-minimum(r,g,b))>15) && 
         (abs(r-g)>15)&&(r>g)&&(r>b)){
   // also skin color
}

Any Help will be appreciated. Thanks in Advance. (PS -my skin ain't white.)

I have to capture skin colour independent of illumination. i used the following criteria(using hsv and rgb) but it ain't working.

  1. if((h<38)&&(h>6)&&(s>.23)&&(s<.68)){then skin clolour}
  2. else if((r>95)&&(g>40)&&(b>20)&&((maximum(r,g,b)-minimum(r,g,b))>15)&&(abs(r-g)>15)&&(r>g)&&(r>b)){then also skin colour}

Any Help will be appreciated. Thanks in Advance. (PS -my skin ain't white.)

I have to capture skin colour independent of illumination. I used the following criteria(using hsv and rgb) but it ain't working:

int h = get_hue(...);
int s = get_saturation(...);
int r = get_red_component(...);
int g = get_green_component(...);
int b = get_blue_component(...);

if ((h<38)&&(h>6)&&(s>0.23)&&(s<0.68)){
    // skin color
}
else if ((r>95) && (g>40) && (b>20) && 
         ((maximum(r,g,b)-minimum(r,g,b))>15) && 
         (abs(r-g)>15)&&(r>g)&&(r>b)){
   // also skin color
}

Any Help will be appreciated. Thanks in Advance. (PS -my skin ain't white.)

Source Link
Roney Island
  • 453
  • 1
  • 4
  • 13
Loading