|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--Texture.TextureAdministrator
This class provides tools to administrate the textures. The textures are in a vector and we can manipulate them.
Texture,
TextureError,
TextureAdministratorError| Field Summary | |
protected Vector |
circleTextureVector
The vector for the circles. |
protected Vector |
polygonTextureVector
The vector for the polygons. |
protected Vector |
rectangleTextureVector
The vector for the rectangles. |
| Constructor Summary | |
TextureAdministrator()
The constructor. |
|
| Method Summary | |
void |
addCircleTexture(int color)
This method add a uniform texture to a circle. |
void |
addCircleTexture(int width,
int height,
int mode)
This method add a "true" texture to a circle. |
void |
addPolygonTexture(int color)
This method add a uniform texture to a polygon. |
void |
addPolygonTexture(int width,
int height,
int mode)
This method add a "true" texture to a polygon. |
void |
addRectangleTexture(int color)
This method add a uniform texture to a rectangle. |
void |
addRectangleTexture(int width,
int height,
int mode)
This method add a "true" texture to a rectangle. |
void |
clearAll()
This method removes all the element of the different vectors. |
int |
indexCircle()
This method returns the size of the circle vector. |
int |
indexPolygon()
This method returns the size of the polygon vector. |
int |
indexRectangle()
This method returns the size of the rectangle vector. |
void |
removeCircleTexture(int indexCircle)
Removes a texture from the circle vector. |
void |
removePolygonTexture(int indexPolygon)
Removes a texture from the polygon vector. |
void |
removeRectangleTexture(int indexRectangle)
Removes a texture from the rectangle vector. |
Texture |
returnCircleTexture(int indexCircle)
This method return the texture associated to a circle. |
Texture |
returnPolygonTexture(int indexPolygon)
This method return the texture associated to a polygon. |
Texture |
returnRectangleTexture(int indexRectangle)
This method return the texture associated to a rectangle. |
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
| Field Detail |
protected Vector circleTextureVector
protected Vector rectangleTextureVector
protected Vector polygonTextureVector
| Constructor Detail |
public TextureAdministrator()
| Method Detail |
public void addCircleTexture(int width,
int height,
int mode)
width - The width of the texture.height - The height of the texture.mode - The mode of the texture.public void addCircleTexture(int color)
color - The color of the texture.
public void addRectangleTexture(int width,
int height,
int mode)
width - The width of the texture.height - The height of the texture.mode - The mode of the texture.public void addRectangleTexture(int color)
color - The color of the texture.
public void addPolygonTexture(int width,
int height,
int mode)
width - The width of the texture.height - The height of the texture.mode - The mode of the texture.public void addPolygonTexture(int color)
color - The color of the texture.
public void removeCircleTexture(int indexCircle)
throws TextureAdministratorError
indexCircle - The index of the vector we want to remove the texture.
public void removeRectangleTexture(int indexRectangle)
throws TextureAdministratorError
indexRectangle - The index of the vector we want to remove the texture.
public void removePolygonTexture(int indexPolygon)
throws TextureAdministratorError
indexPolygon - The index of the vector we want to remove the texture.public void clearAll()
public Texture returnCircleTexture(int indexCircle)
throws TextureAdministratorError
indexCircle - The index in the circle vector we want to acceed the texture.Texture
public Texture returnRectangleTexture(int indexRectangle)
throws TextureAdministratorError
indexRectangle - The index in the rectangle vector we want to acceed the texture.Texture
public Texture returnPolygonTexture(int indexPolygon)
throws TextureAdministratorError
indexPolygon - The index in the polygon vector we want to acceed the texture.Texture,
TextureAdministratorErrorpublic int indexCircle()
public int indexRectangle()
public int indexPolygon()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||