Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

Acme.JPM.Encoders
Class PpmEncoder  view PpmEncoder download PpmEncoder.java

java.lang.Object
  extended byAcme.JPM.Encoders.ImageEncoder
      extended byAcme.JPM.Encoders.PpmEncoder
All Implemented Interfaces:
java.awt.image.ImageConsumer

public class PpmEncoder
extends ImageEncoder

Write out an image as a PPM.

Writes an image onto a specified OutputStream in the PPM file format.

Fetch the software.
Fetch the entire Acme package.


Field Summary
 
Fields inherited from class Acme.JPM.Encoders.ImageEncoder
out
 
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.OutputStream out)
           
PpmEncoder(java.awt.image.ImageProducer prod, java.io.OutputStream out)
           
 
Method Summary
(package private)  void encodeDone()
           
(package private)  void encodePixels(int x, int y, int w, int h, int[] rgbPixels, int off, int scansize)
           
(package private)  void encodeStart(int width, int height)
           
(package private) static void writeString(java.io.OutputStream out, java.lang.String str)
           
 
Methods inherited from class Acme.JPM.Encoders.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

PpmEncoder

public PpmEncoder(java.awt.image.ImageProducer prod,
                  java.io.OutputStream out)
           throws java.io.IOException
Method Detail

encodeStart

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

writeString

static void writeString(java.io.OutputStream out,
                        java.lang.String str)
                 throws java.io.IOException

encodeDone

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

encodePixels

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