|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.threerings.media.util.SingleFrameImageImpl
public class SingleFrameImageImpl
The single frame image class is a basic implementation of the MultiFrameImage interface intended to facilitate the creation of MFIs
whose display frames consist of only a single image.
| Field Summary | |
|---|---|
protected Mirage |
_mirage
The frame image. |
| Constructor Summary | |
|---|---|
SingleFrameImageImpl(Mirage mirage)
Constructs a single frame image object. |
|
| Method Summary | |
|---|---|
int |
getFrameCount()
Returns the number of frames in this multi-frame image. |
int |
getHeight(int index)
Returns the height of the specified frame image. |
int |
getWidth(int index)
Returns the width of the specified frame image. |
boolean |
hitTest(int index,
int x,
int y)
Returns true if the specified frame contains a non-transparent pixel at the specified coordinates. |
void |
paintFrame(Graphics2D g,
int index,
int x,
int y)
Renders the specified frame into the specified graphics object at the specified coordinates. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Mirage _mirage
| Constructor Detail |
|---|
public SingleFrameImageImpl(Mirage mirage)
| Method Detail |
|---|
public int getFrameCount()
MultiFrameImage
getFrameCount in interface MultiFrameImagepublic int getWidth(int index)
MultiFrameImage
getWidth in interface MultiFrameImagepublic int getHeight(int index)
MultiFrameImage
getHeight in interface MultiFrameImage
public void paintFrame(Graphics2D g,
int index,
int x,
int y)
MultiFrameImage
paintFrame in interface MultiFrameImage
public boolean hitTest(int index,
int x,
int y)
MultiFrameImage
hitTest in interface MultiFrameImage
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||