|
Purple Code | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--java.awt.Image
|
+--com.purpletech.awt.PureImage
PureImage - an Image with no ties to any AWT peer nonsense.
PureGraphics| Field Summary | |
protected int[] |
data
|
protected int |
height
|
protected int |
width
|
| Fields inherited from class java.awt.Image |
SCALE_AREA_AVERAGING, SCALE_DEFAULT, SCALE_FAST, SCALE_REPLICATE, SCALE_SMOOTH, UndefinedProperty |
| Constructor Summary | |
PureImage(java.awt.Image src)
Create a new image which is a copy of the given image |
|
PureImage(int width,
int height)
Create a new image with the given width and height. |
|
| Method Summary | |
void |
drawImage(java.awt.Image source,
int xDest,
int yDest,
java.awt.Color bg,
java.awt.image.ImageObserver observer)
just draw an image into this one |
void |
flush()
|
protected int[] |
getData()
returns the int[] array containing the pixel data. |
java.awt.Graphics |
getGraphics()
Creates a graphics context for drawing to an off-screen image. |
int |
getHeight()
|
int |
getHeight(java.awt.image.ImageObserver observer)
Determines the height of the image. |
java.lang.Object |
getProperty(java.lang.String name,
java.awt.image.ImageObserver observer)
Gets a property of this image by name. |
java.awt.Image |
getScaledInstance(int width,
int height,
int hints)
not implemented |
java.awt.image.ImageProducer |
getSource()
Gets the object that produces the pixels for the image. |
int |
getWidth()
|
int |
getWidth(java.awt.image.ImageObserver observer)
Determines the width of the image. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected int width
protected int height
protected int[] data
| Constructor Detail |
public PureImage(java.awt.Image src)
public PureImage(int width,
int height)
| Method Detail |
public int getWidth(java.awt.image.ImageObserver observer)
-1 and the specified
ImageObserver object is notified later.
getWidth in class java.awt.Imageobserver - an object waiting for the image to be loaded.
-1
if the width is not yet known.Image.getHeight(java.awt.image.ImageObserver),
ImageObserverpublic int getHeight(java.awt.image.ImageObserver observer)
-1 and the specified
ImageObserver object is notified later.
getHeight in class java.awt.Imageobserver - an object waiting for the image to be loaded.
-1
if the height is not yet known.Image.getWidth(java.awt.image.ImageObserver),
ImageObserverpublic java.awt.image.ImageProducer getSource()
getSource in class java.awt.ImageImageProducerpublic java.awt.Graphics getGraphics()
getGraphics in class java.awt.ImageGraphics,
Component.createImage(int, int)
public java.lang.Object getProperty(java.lang.String name,
java.awt.image.ImageObserver observer)
Individual property names are defined by the various image
formats. If a property is not defined for a particular image, this
method returns the UndefinedProperty object.
If the properties for this image are not yet known, this method
returns null, and the ImageObserver
object is notified later.
The property name "comment" should be used to store
an optional comment which can be presented to the application as a
description of the image, its source, or its author.
getProperty in class java.awt.Imagename - a property name.observer - an object waiting for this image to be loaded.
ImageObserver,
Image.UndefinedPropertyprotected int[] getData()
PureGraphicspublic int getWidth()
public int getHeight()
public java.awt.Image getScaledInstance(int width,
int height,
int hints)
getScaledInstance in class java.awt.Imagepublic void flush()
flush in class java.awt.Image
public void drawImage(java.awt.Image source,
int xDest,
int yDest,
java.awt.Color bg,
java.awt.image.ImageObserver observer)
xDest - where inside the target to drawyDest - where inside the target to drawbg - background color for transparent pixels (can be null)
|
Documentation generated March 5 2003 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||