i have tried below code that is returning me color of specific pixel which i have pass in argument
int x = (int)event.getX();
int y = (int)event.getY();
int pixel = bitmap.getPixel(x,y);
int redValue = Color.red(pixel);
int blueValue = Color.blue(pixel);
int greenValue = Color.green(pixel);
int[] color={redValue ,blueValue ,greenValue };
btn.setBackgroundColor(getHexColor(color));
public static int getHexColor(int[] color) {
return android.graphics.Color.rgb(color[0], color[1], color[2]);
}
i have also try color palette following link is reference link that is also not returning perfect skin tone color of face
anyone have idea how to extract or get face skin tone color ??