ImageConsumer

Name

ImageConsumer

[Graphic: Figure from the text]

Description

ImageConsumer is an interface that provides the means to consume pixel data and render it for display.

Interface Definition

public abstract interface java.awt.image.ImageConsumer {
 // Constants public final static int COMPLETESCANLINES;
public final static int IMAGEABORTED;
public final static int IMAGEERROR;
public final static int RANDOMPIXELORDER;
public final static int SINGLEFRAME;
public final static int SINGLEFRAMEDONE;
public final static int SINGLEPASS;
public final static int STATICIMAGEDONE;
public final static int TOPDOWNLEFTRIGHT; // Interface Methods public abstract void imageComplete (int status);
public abstract void setColorModel (ColorModel model);
public abstract void setDimensions (int width, int height);
public abstract void setHints (int hints);
public abstract void setPixels (int x, int y, int width, int height, ColorModel model, byte[] pixels, int offset, int scansize);
public abstract void setPixels (int x, int y, int width, int height, ColorModel model, int[] pixels, int offset, int scansize);
public abstract void setProperties (Hashtable properties);
}

Constants

COMPLETESCANLINES

public final static int COMPLETESCANLINES

Hint flag for the setHints(int) method; indicates that the image will be delivered one or more scanlines at a time.

IMAGEABORTED

public final static int IMAGEABORTED

Status flag for the imageComplete(int) method indicating that the loading process for the image aborted.

IMAGEERROR

public final static int IMAGEERROR

Status flag for the imageComplete(int) method indicating that an error happened during image loading.

RANDOMPIXELORDER

public final static int RANDOMPIXELORDER

Hint flag for the setHints(int) method; indicates that the pixels will be delivered in no particular order.

SINGLEFRAME

public final static int SINGLEFRAME

Hint flag for the setHints(int) method; indicates that the image consists of a single frame.

SINGLEFRAMEDONE

public final static int SINGLEFRAMEDONE

Status flag for the imageComplete(int) method indicating a single frame of the image has loaded.

SINGLEPASS

public final static int SINGLEPASS

Hint flag for the setHints(int) method; indicates that each pixel will be delivered once (i.e., the producer will not make multiple passes over the image).

STATICIMAGEDONE

public final static int STATICIMAGEDONE

Status flag for the imageComplete(int) method indicating that the image has fully and successfully loaded, and that there are no additional frames.

TOPDOWNLEFTRIGHT

public final static int TOPDOWNLEFTRIGHT

Hint flag for the setHints(int) method; indicates that pixels will be delivered in a top to bottom, left to right order.

Interface Methods

imageComplete

public abstract void imageComplete (int status)

setColorModel

public abstract void setColorModel (ColorModel model)

setDimensions

public abstract void setDimensions (int width, int height)

setHints

public abstract void setHints (int hints)

setPixels

public abstract void setPixels (int x, int y, int width, int height, ColorModel model, byte[] pixels, int offset, int scansize)

public abstract void setPixels (int x, int y, int width, int height, ColorModel model, int[] pixels, int offset, int scansize)

setProperties

public abstract void setProperties (Hashtable properties)

See Also

ColorModel, Hashtable, ImageFilter, PixelGrabber, Object