com.sun.jimi.core.encoder.sunraster
Class SpecificEncoder
java.lang.Object
|
+--com.sun.jimi.core.encoder.sunraster.SpecificEncoder
- Direct Known Subclasses:
- PaletteSunRasterEncoder, RGBSunRasterEncoder
- public abstract class SpecificEncoder
- extends java.lang.Object
Base class for encoders for specific types of SunRaster images.
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
SpecificEncoder
public SpecificEncoder()
initEncoder
public void initEncoder(SunRasterHeader header,
java.io.OutputStream output,
AdaptiveRasterImage jimiImage)
- Initialize the encoder with the information necessary to write an
encoded image.
- Parameters:
header
- The header for the image.output
- The stream to write the encoded image to.jimiImage
- the JimiImage to draw information from.
doImageEncode
public abstract void doImageEncode()
throws JimiException
- Performs the encoding of the image and writes it to the stream.
writeHeader
protected void writeHeader()
throws java.io.IOException
- Writes the header to the stream.
getHeader
protected SunRasterHeader getHeader()
- Returns the header for the image.
getOutputStream
protected java.io.OutputStream getOutputStream()
- Returns the outputstream to write to.
getJimiImage
protected AdaptiveRasterImage getJimiImage()
- Returns the JimiImage to read information from.