|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Geometry
defines an interface to maintain and render a
three dimensional object.
It is intended that all graphical "entities" be derived from
Geometry
Method Summary | |
Vector[] |
getPoints()
getPoints returns an array of Vectors that represents
each point that makes up the piece of geometry. |
void |
initialize()
initialize sets up any required attributes of the
geometry object. |
void |
render()
render is responsible to presenting the geometry to the
OpenGL context. |
void |
setColor(float red,
float green,
float blue,
float alpha)
setColor sets the color of the geometry. |
void |
setTexture(java.lang.String filename)
setTexture sets the associated texture of this
geometry to the passed texture file. |
Method Detail |
public void initialize()
initialize
sets up any required attributes of the
geometry object. Typically, this includes retrieving the valid
GL and GLU objects.
public void render()
render
is responsible to presenting the geometry to the
OpenGL context.
public void setTexture(java.lang.String filename)
setTexture
sets the associated texture of this
geometry to the passed texture file.
filename
- the image file to use as the texture for this
geometry object.public void setColor(float red, float green, float blue, float alpha)
setColor
sets the color of the geometry. This uses a
RGBA color. Where alpha of 1 is opaque and 0 is clear.
red
- the red color of the geometry.green
- the green color of the geometry;blue
- the green color of the geometry.alpha
- the transparency of the geometry.public Vector[] getPoints()
getPoints
returns an array of Vectors that represents
each point that makes up the piece of geometry.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |