|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.umd.cs.piccolo.POffscreenCanvas
public final class POffscreenCanvas
Offscreen canvas.
Field Summary | |
---|---|
(package private) static int |
DEFAULT_RENDER_QUALITY
Default render quality, PPaintContext.HIGH_QUALITY_RENDERING . |
Constructor Summary | |
---|---|
POffscreenCanvas(int width,
int height)
Create a new offscreen canvas the specified width and height. |
Method Summary | |
---|---|
PCamera |
getCamera()
Return the camera for this offscreen canvas. |
int |
getRenderQuality()
Return the render quality hint for this offscreen canvas. |
void |
paintImmediately()
Sends a repaint notification the repaint manager if PComponent is not already painting immediately. |
void |
popCursor()
Pops the topmost cursor from the stack and sets it as the current one. |
void |
pushCursor(Cursor cursor)
Pushes the given cursor onto the cursor stack and sets the current cursor to the one provided. |
void |
render(Graphics2D graphics)
Render this offscreen canvas to the specified graphics. |
void |
repaint(PBounds repaintBounds)
Called to notify PComponent that given bounds need repainting. |
void |
setCamera(PCamera camera)
Set the camera for this offscreen canvas to camera . |
void |
setInteracting(boolean interacting)
Sets whether the component is currently being interacted with. |
void |
setRenderQuality(int renderQuality)
Set the render quality hint for this offscreen canvas to renderQuality . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
static final int DEFAULT_RENDER_QUALITY
PPaintContext.HIGH_QUALITY_RENDERING
.
Constructor Detail |
---|
public POffscreenCanvas(int width, int height)
width
- width of this offscreen canvas, must be at least zeroheight
- height of this offscreen canvas, must be at least zeroMethod Detail |
---|
public void render(Graphics2D graphics)
graphics
- graphics to render this offscreen canvas to, must not be
nullpublic void setCamera(PCamera camera)
camera
.
camera
- camera for this offscreen canvaspublic PCamera getCamera()
public void setRenderQuality(int renderQuality)
renderQuality
.
renderQuality
- render quality hint, must be one of
PPaintContext.HIGH_QUALITY_RENDERING
or
PPaintContext.LOW_QUALITY_RENDERING
public int getRenderQuality()
public void paintImmediately()
paintImmediately
in interface PComponent
public void popCursor()
popCursor
in interface PComponent
public void pushCursor(Cursor cursor)
pushCursor
in interface PComponent
cursor
- The cursor to set as the current one and pushpublic void repaint(PBounds repaintBounds)
repaint
in interface PComponent
repaintBounds
- bounds needing repaintpublic void setInteracting(boolean interacting)
setInteracting
in interface PComponent
interacting
- whether the component is currently being interacted
with
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |