ZLib and Deflate compression are identical except for the value of the
TIFF Compression field: for ZLib the Compression field has value 8
whereas for Deflate it has value 32946 (0x80b2). In both cases each
image segment (strip or tile) is written as a single complete zlib data
stream.

"EXIF JPEG" is a compression type used when writing the contents of an
APP1 EXIF marker segment for inclusion in a JPEG native image metadata
tree. The contents appended to the output when this compression type is
used are a function of whether an empty or non-empty image is written.
If the image is empty, then a TIFF IFD adhering to the specification of
a compressed EXIF primary IFD is appended. If the image is non-empty,
then a complete IFD and image adhering to the specification of a
compressed EXIF thumbnail IFD and image are appended. Note that the
data of the empty image may not later be appended using the pixel
replacement capability of the TIFF writer.

If ZLib/Deflate or JPEG compression is used, the compression quality
may be set. For ZLib/Deflate the supplied floating point quality value is
rescaled to the range [1, 9] and truncated to an integer
to derive the Deflate compression level. For JPEG the floating point
quality value is passed directly to the JPEG writer plug-in which
interprets it in the usual way.

The canWriteTiles and
canWriteCompressed methods will return
true; the canOffsetTiles and
canWriteProgressive methods will return
false.

If tiles are being written, then each of their dimensions will be
rounded to the nearest multiple of 16 per the TIFF specification. If
JPEG-in-TIFF compression is being used, and tiles are being written
each tile dimension will be rounded to the nearest multiple of 8 times
the JPEG minimum coded unit (MCU) in that dimension. If JPEG-in-TIFF
compression is being used and strips are being written, the number of
rows per strip is rounded to a multiple of 8 times the maximum MCU over
both dimensions.

setColorConverter(TIFFColorConverter colorConverter,
int photometricInterpretation)
Sets the TIFFColorConverter object describing the
color space to which the input data should be converted for
storage in the input stream.

If compressionType is set to a value different from
that supported by the TIFFCompressor then the
compressor object will not be used.

If the compression type supported by the supplied
TIFFCompressor is not among those in
compressionTypes,
then it will be appended to this array after removing any previously
appended compression type. If compressor is
null this will also cause any previously appended
type to be removed from the array.

Parameters:

compressor - the TIFFCompressor to be
used for encoding, or null to allow the writer to
choose its own.

setColorConverter

Sets the TIFFColorConverter object describing the
color space to which the input data should be converted for
storage in the input stream. In addition, the value to be
written to the PhotometricInterpretation tag is
supplied.

Parameters:

colorConverter - a TIFFColorConverter object,
or null.

photometricInterpretation - the value to be written to the
PhotometricInterpretation tag in the root IFD.