org.freehep.graphicsio.ppm
Class PPMEncoder

java.lang.Object
  extended by org.freehep.graphicsio.ppm.ImageEncoder
      extended by org.freehep.graphicsio.ppm.PPMEncoder
All Implemented Interfaces:
java.awt.image.ImageConsumer

public class PPMEncoder
extends ImageEncoder


Field Summary
 
Fields inherited from class org.freehep.graphicsio.ppm.ImageEncoder
out, props
 
Fields inherited from interface java.awt.image.ImageConsumer
COMPLETESCANLINES, IMAGEABORTED, IMAGEERROR, RANDOMPIXELORDER, SINGLEFRAME, SINGLEFRAMEDONE, SINGLEPASS, STATICIMAGEDONE, TOPDOWNLEFTRIGHT
 
Constructor Summary
PPMEncoder(java.awt.Image img, java.io.DataOutput dos)
           
PPMEncoder(java.awt.Image img, java.io.OutputStream out)
           
PPMEncoder(java.awt.image.ImageProducer prod, java.io.DataOutput dos)
           
PPMEncoder(java.awt.image.ImageProducer prod, java.io.OutputStream out)
           
 
Method Summary
 void addComment(java.lang.String comment)
           
protected  void encodeDone()
           
protected  void encodePixels(int x, int y, int w, int h, int[] rgbPixels, int off, int scansize)
           
protected  void encodeStart(int width, int height)
           
 
Methods inherited from class org.freehep.graphicsio.ppm.ImageEncoder
encode, imageComplete, setColorModel, setDimensions, setHints, setPixels, setPixels, setProperties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PPMEncoder

public PPMEncoder(java.awt.Image img,
                  java.io.OutputStream out)
           throws java.io.IOException
Throws:
java.io.IOException

PPMEncoder

public PPMEncoder(java.awt.Image img,
                  java.io.DataOutput dos)
           throws java.io.IOException
Throws:
java.io.IOException

PPMEncoder

public PPMEncoder(java.awt.image.ImageProducer prod,
                  java.io.OutputStream out)
           throws java.io.IOException
Throws:
java.io.IOException

PPMEncoder

public PPMEncoder(java.awt.image.ImageProducer prod,
                  java.io.DataOutput dos)
           throws java.io.IOException
Throws:
java.io.IOException
Method Detail

addComment

public void addComment(java.lang.String comment)

encodeStart

protected void encodeStart(int width,
                           int height)
                    throws java.io.IOException
Specified by:
encodeStart in class ImageEncoder
Throws:
java.io.IOException

encodePixels

protected void encodePixels(int x,
                            int y,
                            int w,
                            int h,
                            int[] rgbPixels,
                            int off,
                            int scansize)
                     throws java.io.IOException
Specified by:
encodePixels in class ImageEncoder
Throws:
java.io.IOException

encodeDone

protected void encodeDone()
                   throws java.io.IOException
Specified by:
encodeDone in class ImageEncoder
Throws:
java.io.IOException


Copyright © 2000-2007 FreeHEP. All Rights Reserved.