public int[] getPixel(int x, int y, int iArray[], DataBuffer data) { if ((x < 0) || (y < 0) || (x >= width) || (y >= height)) { throw new ArrayIndexOutOfBoundsException("Coordinate out of bounds!"); } int pixels[]; if (iArray != null) { pixels = iArray; } else { pixels = new int[numBands]; } int bitnum = dataBitOffset + x * pixelBitStride; int element = data.getElem(y * scanlineStride + bitnum / dataElementSize); int shift = dataElementSize - (bitnum & (dataElementSize - 1)) - pixelBitStride; pixels[0] = (element >> shift) & bitMask; return pixels; }
public int[] getPixel(int x, int y, int[] iArray, DataBuffer data) { if (iArray == null) iArray = new int[1]; iArray[0] = getSample(x, y, 0, data);  return iArray; }
	public int[] getPixel(int x, int y, int iArray[], DataBuffer data) {		if ((x < 0) || (y < 0) || (x >= width) || (y >= height)) {			throw new ArrayIndexOutOfBoundsException("Coordinate out of bounds!");		}		int pixels[];		if (iArray != null) {			pixels = iArray;		} else {			pixels = new int[numBands];		}		int bitnum = dataBitOffset + x * pixelBitStride;		int element = data.getElem(y * scanlineStride + bitnum / dataElementSize);		int shift = dataElementSize - (bitnum & (dataElementSize - 1)) - pixelBitStride;		pixels[0] = (element >> shift) & bitMask;		return pixels;	}