List of utility methods to do Pixel Convert To
void | pixelToRGB(int pixel, int[] prgb) pixel To RGB prgb[0] = (pixel & 0xff0000) >> 16; prgb[1] = (pixel & 0xff00) >> 8; prgb[2] = pixel & 0xff; |
int[] | pixelXYToTileXY(int pixelX, int pixelY) Converts pixel XY coordinates into tile XY coordinates of the tile containing the specified pixel. int tileX, tileY; tileX = pixelX / 256; tileY = pixelY / 256; return new int[] { tileX, tileY }; |