com.jme3.scene.control
Class AbstractControl
java.lang.Object
com.jme3.scene.control.AbstractControl
- All Implemented Interfaces:
- Savable, Control
- Direct Known Subclasses:
- AnimControl, BillboardControl, CameraControl, LightControl, LodControl, NormalRecalcControl, SkeletonControl, TerrainLodControl, UpdateControl
public abstract class AbstractControl
- extends java.lang.Object
- implements Control
An abstract implementation of the Control interface.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
enabled
protected boolean enabled
spatial
protected Spatial spatial
AbstractControl
public AbstractControl()
setSpatial
public void setSpatial(Spatial spatial)
- Specified by:
setSpatial
in interface Control
- Parameters:
spatial
- the spatial to be controlled. This should not be called
from user code.
getSpatial
public Spatial getSpatial()
setEnabled
public void setEnabled(boolean enabled)
isEnabled
public boolean isEnabled()
controlUpdate
protected abstract void controlUpdate(float tpf)
- To be implemented in subclass.
controlRender
protected abstract void controlRender(RenderManager rm,
ViewPort vp)
- To be implemented in subclass.
update
public void update(float tpf)
- Description copied from interface:
Control
- Updates the control. This should not be called from user code.
- Specified by:
update
in interface Control
- Parameters:
tpf
- Time per frame.
render
public void render(RenderManager rm,
ViewPort vp)
- Description copied from interface:
Control
- Should be called prior to queuing the spatial by the RenderManager. This
should not be called from user code.
- Specified by:
render
in interface Control
write
public void write(JmeExporter ex)
throws java.io.IOException
- Specified by:
write
in interface Savable
- Throws:
java.io.IOException
read
public void read(JmeImporter im)
throws java.io.IOException
- Specified by:
read
in interface Savable
- Throws:
java.io.IOException