numColors = 1 << ((infoHeader[14] & 0xFF) | ((infoHeader[15] & 0xFF) << 8));
numColors = 1 << bitCount;
PaletteData loadPalette(byte[] infoHeader) {	int depth = (infoHeader[14] & 0xFF) | ((infoHeader[15] & 0xFF) << 8);	if (depth <= 8) {		int numColors = (infoHeader[32] & 0xFF) | ((infoHeader[33] & 0xFF) << 8) | ((infoHeader[34] & 0xFF) << 16) | ((infoHeader[35] & 0xFF) << 24);		if (numColors == 0) {			numColors = 1 << ((infoHeader[14] & 0xFF) | ((infoHeader[15] & 0xFF) << 8));		} else {			if (numColors > 256)				numColors = 256;		}		byte[] buf = new byte[numColors * 4];		try {			if (inputStream.read(buf) != buf.length)				SWT.error(SWT.ERROR_INVALID_IMAGE);		} catch (IOException e) {			SWT.error(SWT.ERROR_IO, e);		}		return paletteFromBytes(buf, numColors);	}	if (depth == 16) return new PaletteData(0x7C00, 0x3E0, 0x1F);	if (depth == 24) return new PaletteData(0xFF, 0xFF00, 0xFF0000);	return new PaletteData(0xFF00, 0xFF0000, 0xFF000000);}