|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.ohiou.cs456_badabing.sceneapi.basic.ANode
edu.ohiou.cs456_badabing.sceneapi.visualize.Sphere
public class Sphere
draws Spheres.
Description: This class extends ANode, and renders a sphere.
Copyright: Copyright (c) 2008, Lev A Neiman
Company: Ohio University EECS
| Field Summary | |
|---|---|
private static int |
detail
detail to use for Sphere. |
private static int |
g_disp_list
display list handle. |
private static Material |
mtl
material to use for all spheres. |
static boolean |
need_to_generate_display_list
if this is true, then display list needs to be (re)generated. |
private float |
radius
size of the sphere as radius. |
| Fields inherited from class edu.ohiou.cs456_badabing.sceneapi.basic.ANode |
|---|
children, display_list, name, no_disp_list, parent, ppop, rotation, rotation_angle, scale, show, translation |
| Constructor Summary | |
|---|---|
Sphere()
default constructor. |
|
| Method Summary | |
|---|---|
float |
getRadius()
return radius. |
void |
render(GLAutoDrawable panel)
generates display list if needed. |
void |
setRadius(float new_radius)
sets the new radius for this sphere. |
static void |
setTransperency(float new_transperency)
set new transpereny for all Spheres. |
| Methods inherited from class edu.ohiou.cs456_badabing.sceneapi.basic.ANode |
|---|
addChild, countNodes, drawCube, getName, getNormal, hideTree, pushPop, renderTree, rotation, scale, setName, setParent, setPushPop, showTree, translation |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private float radius
private static int detail
private static Material mtl
public static boolean need_to_generate_display_list
private static int g_disp_list
| Constructor Detail |
|---|
public Sphere()
| Method Detail |
|---|
public static void setTransperency(float new_transperency)
new_transperency - floatpublic void setRadius(float new_radius)
new_radius - floatpublic float getRadius()
public void render(GLAutoDrawable panel)
render in class ANodepanel - GLAutoDrawable
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||