0

Now I have 2 dimension array that collects all color's pixel and I have 1 dimension array that collects a specific color that every pixel need to check with this array. But how to check this 2 arrays
first array is array_A = new String[bitmap.getWidth()][bitmap.getHeight()];

Another is final String[] array_B = { "ffcc33","ffcc00",....} so how can I check this 2 arrays :)) Thanks in Advance

Mint
  • 47
  • 1
  • 4

1 Answers1

1

Hope that snippets would help you. Also, you can use pixel[] = new int [width*height] to get pixel from image.

for(int w= 0; w < bitmap.getwidth(); w++)
{
    for(int h = 0 ; h < bitmap,getheight() ; h++ )
    {
        int c = bitmap.getPixel(w, h);
        Log.i("Pixels", h+"X"+w);
    }
}
Mat
  • 202,337
  • 40
  • 393
  • 406