| java.lang.Object | |
| ↳ | casmi.graphics.Graphics |
Wrapper of JOGL to make it easy to use.
| Nested Classes | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Graphics.MatrixMode | |||||||||||
| Public Constructors | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Public Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
Applies the transformation matrix.
| |||||||||||
Starts to draw polygon.
| |||||||||||
Disables texture.
| |||||||||||
Enables texture.
| |||||||||||
Ends to draw polygon.
| |||||||||||
Returns the height of the display window.
| |||||||||||
Returns the width of the display window.
| |||||||||||
Loads the transformation matrix.
| |||||||||||
Sets the MatrixMode.
| |||||||||||
Replaces the current transformation matrix with the top of the stack.
| |||||||||||
Pushes a copy of the current transformation matrix onto the stack.
| |||||||||||
Resets the current transformation matrix.
| |||||||||||
Rotates about a vector in space.
| |||||||||||
Rotates around the X axis.
| |||||||||||
Rotates around the Y axis.
| |||||||||||
Rotates around the Z axis.
| |||||||||||
Scales in all dimensions.
| |||||||||||
Scales in X and Y.
| |||||||||||
Scales in X ,Y and Z.
| |||||||||||
Sets the color value and the position of the ambientLight
| |||||||||||
Sets the RGB value and the position of the ambientLight
| |||||||||||
Sets the RBG value and the position of the No.i ambientLight
| |||||||||||
Sets the RGB value and the position of the ambientLight
| |||||||||||
Sets the color value and the position of the No.i ambientLight
| |||||||||||
Sets the RGB value of the No.i ambientLight
| |||||||||||
Sets the RBG value and the position of the No.i ambientLight
| |||||||||||
Sets the color value of the No.i ambientLight
| |||||||||||
Sets the RGB value of the ambientLight
| |||||||||||
Sets the color value of the ambientLight
| |||||||||||
Sets the background to a RGB or HSB and alpha value.
| |||||||||||
Sets the background to a RGB and alpha value.
| |||||||||||
Sets the background to a grayscale value.
| |||||||||||
Sets the background to a RGB and value.
| |||||||||||
Sets the background to a grayscale value.
| |||||||||||
Sets the default camera position.
| |||||||||||
Sets the position of the camera through setting the eye position, the
center of the scene, and which axis is facing upward.
| |||||||||||
Sets the color value and the position of the No.i directionalLight
| |||||||||||
Sets the color value and the position of the No.i directionalLight
| |||||||||||
Sets a perspective matrix defined through the parameters.
| |||||||||||
Sets the height of the display window.
| |||||||||||
Set attenuation rates for point lights, spot lights, and ambient lights.
| |||||||||||
Sets the diffuse color for No.i light.
| |||||||||||
Sets the specular color for No.i light.
| |||||||||||
Sets the default orthographic projection.
| |||||||||||
Sets an orthographic projection and defines a parallel clipping volume.
| |||||||||||
Sets a perspective projection applying foreshortening, making distant objects appear smaller
than closer ones.
| |||||||||||
Sets a default perspective.
| |||||||||||
Sets the color value and the position of the No.i pointLight
| |||||||||||
Sets the color value and the position of the No.i pointLight
| |||||||||||
Sets the color value, position, direction and the angle of the spotlight cone of the No.i spotLight
| |||||||||||
Sets texture vertex(nx,ny) at position v.
| |||||||||||
Sets texture vertex(nx,ny) at position(x,y,z).
| |||||||||||
Sets texture vertex(nx,ny) at position(x,y).
| |||||||||||
Sets the width of the display window.
| |||||||||||
Translates in X, Y and Z.
| |||||||||||
Translates in X and Y.
| |||||||||||
|
[Expand]
Inherited Methods | |||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
Applies the transformation matrix.
Starts to draw polygon.
Ends to draw polygon.
Returns the height of the display window.
Returns the width of the display window.
Loads the transformation matrix.
Sets the MatrixMode.
| mode | Either PROJECTION or MODELVIEW |
|---|
Replaces the current transformation matrix with the top of the stack.
Pushes a copy of the current transformation matrix onto the stack.
Resets the current transformation matrix.
Rotates about a vector in space. Same as the glRotated() function.
Rotates around the X axis.
Rotates around the Y axis.
Rotates around the Z axis.
Scales in all dimensions.
Scales in X and Y. Equivalent to scale(sx, sy, 1).
Scales in X ,Y and Z.
Sets the color value and the position of the ambientLight
Sets the RGB value and the position of the ambientLight
Sets the RBG value and the position of the No.i ambientLight
Sets the RGB value and the position of the ambientLight
Sets the color value and the position of the No.i ambientLight
Sets the RGB value of the No.i ambientLight
Sets the RBG value and the position of the No.i ambientLight
Sets the color value of the No.i ambientLight
Sets the RGB value of the ambientLight
Sets the background to a RGB or HSB and alpha value.
| color | The RGB or HSB value of the background. |
|---|
Sets the background to a RGB and alpha value.
| x | The R value of the background. |
|---|---|
| y | The G value of the background. |
| z | The B value of the background. |
| a | The alpha opacity of the background. |
Sets the background to a grayscale value.
| gray | The grayscale value of the background. |
|---|
Sets the background to a RGB and value.
| x | The R value of the background. |
|---|---|
| y | The G value of the background. |
| z | The B value of the background. |
Sets the background to a grayscale value.
| gray | The grayscale value of the background. |
|---|---|
| alpha | The alpha opacity of the background. |
Sets the default camera position.
Sets the position of the camera through setting the eye position, the center of the scene, and which axis is facing upward. Moving the eye position and the direction it is pointing (the center of the scene) allows the images to be seen from different angles.
| eyeX | x-coordinate for the eye |
|---|---|
| eyeY | y-coordinate for the eye |
| eyeZ | z-coordinate for the eye |
| centerX | x-coordinate for the center of the scene |
| centerY | x-coordinate for the center of the scene |
| centerZ | z-coordinate for the center of the scene |
| upX | usually 0.0, 1.0, or -1.0 |
| upY | usually 0.0, 1.0, or -1.0 |
| upZ | usually 0.0, 1.0, or -1.0 |
Sets the color value and the position of the No.i directionalLight
Sets the color value and the position of the No.i directionalLight
Sets a perspective matrix defined through the parameters. Works like glFrustum, except it wipes out the current perspective matrix rather than multiplying itself with it.
| left | left coordinate of the clipping plane |
|---|---|
| right | right coordinate of the clipping plane |
| bottom | bottom coordinate of the clipping plane |
| top | top coordinate of the clipping plane |
| near | near component of the clipping plane |
| far | far component of the clipping plane |
Sets the height of the display window.
Set attenuation rates for point lights, spot lights, and ambient lights.
Sets the default orthographic projection.
Sets an orthographic projection and defines a parallel clipping volume. All objects with the same dimension appear the same size, regardless of whether they are near or far from the camera. The parameters to this function specify the clipping volume where left and right are the minimum and maximum x values, top and bottom are the minimum and maximum y values, and near and far are the minimum and maximum z values.
| left | left plane of the clipping volume |
|---|---|
| right | right plane of the clipping volume |
| bottom | bottom plane of the clipping volume |
| top | top plane of the clipping volume |
| near | maximum distance from the origin to the viewer |
| far | maximum distance from the origin away from the viewer |
Sets a perspective projection applying foreshortening, making distant objects appear smaller than closer ones. The parameters define a viewing volume with the shape of truncated pyramid. Objects near to the front of the volume appear their actual size, while farther objects appear smaller. This projection simulates the perspective of the world more accurately than orthographic projection.
| fov | field-of-view angle for vertical direction |
|---|---|
| aspect | ratio of width to height |
| zNear | z-position of nearest clipping plane |
| zFar | z-position of nearest farthest plane |
Sets a default perspective.
Sets the color value and the position of the No.i pointLight
Sets the color value and the position of the No.i pointLight
Sets the color value, position, direction and the angle of the spotlight cone of the No.i spotLight
Sets texture vertex(nx,ny) at position(x,y,z).
Sets texture vertex(nx,ny) at position(x,y).
Sets the width of the display window.
Translates in X, Y and Z.
Translates in X and Y.