|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.scilab.forge.scirenderer.implementation.g2d.texture.G2DTextureDrawingTools
public class G2DTextureDrawingTools
Implementation of TextureDrawingTools.
This implementation create a TextureBufferedImage an fill it with sprite drawing.
| Constructor Summary | |
|---|---|
G2DTextureDrawingTools(java.awt.Graphics2D g2d)
Default constructor. |
|
| Method Summary | |
|---|---|
void |
accept(Texture texture)
|
void |
accept(TextureDrawer textureDrawer,
int width,
int height)
Ask this image to accept a sprite drawer. |
void |
clear(Color color)
Clear the sprite with the given color. |
void |
draw(javax.swing.Icon icon,
int x,
int y)
Draw the given Icon at the given position. |
void |
draw(TextEntity textEntity,
int x,
int y)
Draw the given text at the given position with the given appearance. |
void |
drawCircle(int x,
int y,
int diameter,
Appearance appearance)
Draw a circle. |
void |
drawPolyline(int[] coordinates,
Appearance appearance)
Draw a polyline. |
void |
fillDisc(int x,
int y,
int diameter,
Color color)
Fill a disc of given diameter, centered at (x, y) with the given appearance. |
void |
fillPolygon(int[] coordinates,
Appearance appearance)
Fill a polygon. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public G2DTextureDrawingTools(java.awt.Graphics2D g2d)
width - the image width.height - the image height.useSquareTexture - true if square texture is needed.| Method Detail |
|---|
public void accept(Texture texture)
public void accept(TextureDrawer textureDrawer,
int width,
int height)
spriteDrawer - the given sprite drawer.
public void drawPolyline(int[] coordinates,
Appearance appearance)
TextureDrawingTools
drawPolyline in interface TextureDrawingToolscoordinates - polyline's point coordinates.appearance - the used appearance.
public void fillPolygon(int[] coordinates,
Appearance appearance)
TextureDrawingTools
fillPolygon in interface TextureDrawingToolscoordinates - polygon's point coordinates.appearance - the used appearance.
public void drawCircle(int x,
int y,
int diameter,
Appearance appearance)
TextureDrawingTools
drawCircle in interface TextureDrawingToolsx - the x coordinate of the circle center.y - the y coordinate of the circle center.diameter - the circle diameter.appearance - the circle appearance.
public void fillDisc(int x,
int y,
int diameter,
Color color)
TextureDrawingTools
fillDisc in interface TextureDrawingToolsx - the x coordinate of the disc center.y - the y coordinate of the disc center.diameter - the disc diameter.color - the disc color.
public void draw(TextEntity textEntity,
int x,
int y)
TextureDrawingTools
draw in interface TextureDrawingToolstextEntity - the text entity to draw.x - the x text position.y - the y text position.
public void draw(javax.swing.Icon icon,
int x,
int y)
TextureDrawingToolsIcon at the given position.
draw in interface TextureDrawingToolsicon - the given icon to paint.x - the x text position.y - the y text position.public void clear(Color color)
TextureDrawingTools
clear in interface TextureDrawingToolscolor - the new background color.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||