|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.threerings.opengl.util.SimpleRenderable
com.threerings.opengl.util.SimpleTransformable
com.threerings.opengl.scene.SimpleSceneElement
public abstract class SimpleSceneElement
Extends SimpleTransformable and provides a basic implementation of the
SceneElement interface.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface com.threerings.opengl.scene.SceneElement |
|---|
SceneElement.TickPolicy |
| Constructor Summary | |
|---|---|
SimpleSceneElement(GlContext ctx)
Creates a new scene element. |
|
SimpleSceneElement(GlContext ctx,
String queue)
Creates a new simple scene element. |
|
SimpleSceneElement(GlContext ctx,
String queue,
int priority)
Creates a new simple scene element. |
|
SimpleSceneElement(GlContext ctx,
String queue,
int priority,
boolean modifiesColorState,
int primitiveCount)
Creates a new simple scene element. |
|
| Method Summary | |
|---|---|
Box |
getBounds()
Returns a reference to the bounds of the object. |
boolean |
getIntersection(Ray3D ray,
Vector3f result)
Finds the intersection of a ray with this object and places it in the supplied vector (if it exists). |
SceneElement.TickPolicy |
getTickPolicy()
Returns the policy that determines when the Tickable.tick(float) method must be called. |
Object |
getUserObject()
Returns this element's user object reference. |
void |
setInfluences(SceneInfluenceSet influences)
Sets the influences affecting this element. |
void |
setTickPolicy(SceneElement.TickPolicy policy)
Sets the element's tick policy. |
void |
setTransform(Transform3D transform)
Sets the transform to the specified value and promotes it to Transform3D.UNIFORM,
then updates the bounds of the element. |
void |
setUserObject(Object object)
Sets the element's user object reference. |
void |
tick(float elapsed)
Updates the state of this object based on the elapsed time in seconds. |
void |
updateBounds()
Updates the bounds of the element. |
boolean |
updateLastVisit(int visit)
Checks and updates the last visit value. |
void |
wasAdded(Scene scene)
Notes that the element was added to the specified scene. |
void |
willBeRemoved()
Notes that the element will be removed from the scene. |
| Methods inherited from class com.threerings.opengl.util.SimpleTransformable |
|---|
enqueue, getTransform |
| Methods inherited from class com.threerings.opengl.util.SimpleRenderable |
|---|
composite, getStates |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.threerings.opengl.compositor.Compositable |
|---|
composite |
| Constructor Detail |
|---|
public SimpleSceneElement(GlContext ctx)
public SimpleSceneElement(GlContext ctx,
String queue)
queue - the name of the queue into which we place the batch.
public SimpleSceneElement(GlContext ctx,
String queue,
int priority)
queue - the name of the queue into which we place the batch.priority - the priority level at which to enqueue the batch.
public SimpleSceneElement(GlContext ctx,
String queue,
int priority,
boolean modifiesColorState,
int primitiveCount)
queue - the name of the queue into which we place the batch.priority - the priority level at which to enqueue the batch.modifiesColorState - if true, invalidate the color state after calling the
SimpleRenderable.draw() method.primitiveCount - the primitive count to report to the renderer.| Method Detail |
|---|
public void setTickPolicy(SceneElement.TickPolicy policy)
public void setUserObject(Object object)
public void setTransform(Transform3D transform)
Transform3D.UNIFORM,
then updates the bounds of the element.
public void updateBounds()
getLocalBounds().
public SceneElement.TickPolicy getTickPolicy()
SceneElementTickable.tick(float) method must be called.
getTickPolicy in interface SceneElementpublic Object getUserObject()
SceneElement
getUserObject in interface SceneElementpublic void wasAdded(Scene scene)
SceneElement
wasAdded in interface SceneElementpublic void willBeRemoved()
SceneElement
willBeRemoved in interface SceneElementpublic void setInfluences(SceneInfluenceSet influences)
SceneElement
setInfluences in interface SceneElementpublic Box getBounds()
SceneObject
getBounds in interface SceneObjectpublic boolean updateLastVisit(int visit)
SceneObject
updateLastVisit in interface SceneObjectpublic void tick(float elapsed)
Tickable
tick in interface Tickable
public boolean getIntersection(Ray3D ray,
Vector3f result)
Intersectable
getIntersection in interface Intersectable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||