com.sun.jimi.core.encoder.bmp
Class BMPEncoder

java.lang.Object
  |
  +--com.sun.jimi.core.util.ProgressMonitorSupport
        |
        +--com.sun.jimi.core.compat.JimiEncoderBase
              |
              +--com.sun.jimi.core.encoder.bmp.BMPEncoder

public class BMPEncoder
extends JimiEncoderBase
implements BMPEncoderIfc

Save an image in Windows BMP format. Currently limited to saving image in 24-bit format.


Fields inherited from class com.sun.jimi.core.compat.JimiEncoderBase
currentImage, DONE, ERROR, factory, MAX_COLORS_RGB, MULTIIMAGE, NEXTIMAGE
 
Fields inherited from class com.sun.jimi.core.util.ProgressMonitorSupport
currentProgressLevel, progressListener
 
Constructor Summary
BMPEncoder()
           
 
Method Summary
protected  BMPEncoderIfc createEncoderForImage(AdaptiveRasterImage image)
           
 boolean driveEncoder()
          This only runs onece therefore no state handling to deal with
 void encodeBMP(BMPEncoder decoder, AdaptiveRasterImage ji, LEDataOutputStream out)
          Write out the data contained in the JimiImage to the output stream in the bmp file format.
 void freeEncoder()
           
 int getState()
           
 void initSpecificEncoder(java.io.OutputStream out, AdaptiveRasterImage ji)
           
 
Methods inherited from class com.sun.jimi.core.compat.JimiEncoderBase
createAdaptiveRasterImage, createAdaptiveRasterImage, encodeImage, encodeImage, encodeImages, encodeImages, getCapabilties, getJimiImage, getMaxColors, setJimiImage, setNumberOfImages, setProgress
 
Methods inherited from class com.sun.jimi.core.util.ProgressMonitorSupport
setProgressListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BMPEncoder

public BMPEncoder()
Method Detail

initSpecificEncoder

public void initSpecificEncoder(java.io.OutputStream out,
                                AdaptiveRasterImage ji)
                         throws JimiException
Overrides:
initSpecificEncoder in class JimiEncoderBase

driveEncoder

public boolean driveEncoder()
                     throws JimiException
This only runs onece therefore no state handling to deal with
Overrides:
driveEncoder in class JimiEncoderBase

freeEncoder

public void freeEncoder()
                 throws JimiException
Overrides:
freeEncoder in class JimiEncoderBase

getState

public int getState()
Overrides:
getState in class JimiEncoderBase

encodeBMP

public void encodeBMP(BMPEncoder decoder,
                      AdaptiveRasterImage ji,
                      LEDataOutputStream out)
               throws JimiException
Write out the data contained in the JimiImage to the output stream in the bmp file format. Chooses between 8bpp and 24bpp depending on the ColorModel of the image
Specified by:
encodeBMP in interface BMPEncoderIfc

createEncoderForImage

protected BMPEncoderIfc createEncoderForImage(AdaptiveRasterImage image)