|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object image.Image
public abstract class Image
An abstract class representing an Image. See subclasses for specific implementations.
Method Summary | |
---|---|
RasterImage |
flipHorizontal()
Return a version of this Image flipped horizontally (left to right). |
RasterImage |
flipVertical()
Return a version of this Image flipped vertically (top to bottom). |
abstract int |
height()
Calculate the height of this Image |
Image |
overlay(Image top)
Overlay the given Image over this Image |
Image |
overlay(Image top,
Image next,
Image... imgs)
Overlay the given Images over this Image |
Image |
overlayxy(double x,
double y,
Image top)
Overlay the given Image over this Image offset (x,y) |
Image |
overlayxy(Image top,
double x,
double y)
Overlay the given Image over this Image offset (x,y) |
Image |
overlayxy(Image top,
int x,
int y)
Overlay the given Image over this Image offset (x,y) |
Image |
overlayxy(Image top,
Posn p)
Overlay the given Image over this Image offset Posn |
Image |
overlayxy(int x,
int y,
Image top)
Overlay the given Image over this Image offset (x,y) |
Image |
overlayxy(Posn p,
Image top)
Overlay the given Image over this Image offset Posn |
abstract void |
paint(java.awt.Graphics g,
int x,
int y)
Draw this image into a Graphics |
RasterImage |
rasterize()
Return a raster (buffered) version of this Image |
RasterImage |
rotate(double ang)
Return a rotated version of this image by the given angle in degrees. |
Image |
rotate(int ang)
Return a rotated version of this image by the given angle in degrees. |
boolean |
toFile(java.lang.String name)
Save this image to a file |
Scene |
toScene()
Convert this image into a Scene containing the image without a background |
boolean |
toWhiteFile(java.lang.String name)
Save this image to a file |
Scene |
toWhiteScene()
Convert this image into a Scene containing the image with a white background |
abstract int |
width()
Calculate the width of this Image |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public Image overlay(Image top)
public Image overlay(Image top, Image next, Image... imgs)
public Image overlayxy(Image top, int x, int y)
public Image overlayxy(Image top, double x, double y)
public Image overlayxy(Image top, Posn p)
public Image overlayxy(int x, int y, Image top)
public Image overlayxy(double x, double y, Image top)
public Image overlayxy(Posn p, Image top)
public abstract void paint(java.awt.Graphics g, int x, int y)
public abstract int width()
public abstract int height()
public Scene toScene()
public Scene toWhiteScene()
public boolean toFile(java.lang.String name)
public boolean toWhiteFile(java.lang.String name)
public RasterImage rasterize()
public Image rotate(int ang)
public RasterImage rotate(double ang)
Any Image may be rotated several times, though for efficiency (when possible) the rotated image should be saved, rather than recreated.
public RasterImage flipHorizontal()
public RasterImage flipVertical()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |