GetMapRequest request = mapContext.getRequest();
final String format = request.getFormat();
// do we want it to be 8 bits?
if (format.equalsIgnoreCase(IMAGE_TIFF8) || (mapContext.getPaletteInverter() != null)) {
InverseColorMapOp paletteInverter = mapContext.getPaletteInverter();
image = forceIndexed8Bitmask(image, paletteInverter);
}
// write it out
try {