IIOParam Classes

By default, the ImageReader's read method does not offer much control over how the input image is read. Similarly, neither does the ImageWriter's write method offer much control over how the output image is written. One way to achieve more control in both of these situations is by using an object of the javax.imageio.IIOParam class. This class provides methods for describing how an image stream should be encoded and decoded. The IIOParam class contains one subclass for image reading, and one subclass for image writing. They are javax.imageio.ImageReadParams and javax.imageio.ImageWriteParams, respectively.

ImageReadParam

A javax.imageio.ImageReadParam object can be obtained using the following ImageReader method:

 public ImageReadParam ...

Get Java™ Media APIs: Cross-Platform Imaging, Media, and Visualization now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.