ImageOutputStream
, the existing contents of the output prior to the current seek position may be flushed, and need not be readable or writable, unless the plug-in needs to be able to patch up the header information when endWriteSequence
is called (e.g. TIFF). If canWriteSequence
returns false
, this method will throw an UnsupportedOperationException
.
The output must have been set beforehand using the setOutput
method.
prepareWriteSequence
must have been called beforehand, or an IllegalStateException
is thrown.
If canWriteRasters
returns true
, the IIOImage
may contain a Raster
source. Otherwise, it must contain a RenderedImage
source.
The supplied thumbnails will be resized if needed, and any thumbnails in excess of the supported number will be ignored. If the format requires additional thumbnails that are not provided, the writer will generate them internally.
An ImageWriteParam
may optionally be supplied to control the writing process. If param
is null
, a default write param will be used.
If the supplied ImageWriteParam
contains optional setting values not supported by this writer (e.g. progressive encoding or any format-specific settings), they will be ignored.
The default implementation throws an IllegalStateException
if the output is null
, and otherwise throws an UnsupportedOperationException
.
@param image an IIOImage
object containing animage, thumbnails, and metadata to be written.
@param param an ImageWriteParam
, ornull
to use a default ImageWriteParam
.
@exception IllegalStateException if the output has notbeen set, or prepareWriteSequence
has not been called.
@exception UnsupportedOperationException ifcanWriteSequence
returns false
.
@exception IllegalArgumentException if image
isnull
.
@exception UnsupportedOperationException if image
contains a Raster
and canWriteRasters
returns false
.
@exception IOException if an error occurs during writing.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|