|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsyn3d.base.ActiveNode
syn3d.nodes.GroupNode
syn3d.nodes.SceneNode
syn3d.nodes.xith3d.SceneNodeXith3D
public class SceneNodeXith3D
Nested Class Summary |
---|
Nested classes/interfaces inherited from class syn3d.nodes.SceneNode |
---|
SceneNode.SceneTimerTask |
Field Summary | |
---|---|
protected BranchGroup |
branchgroup
|
protected Frame3DXith3D |
frame
|
protected int |
lightRotationMode
|
protected DirectionalLight[] |
lights
|
protected Shape3D |
lightVector
|
protected Locale |
locale
|
protected PluginManager |
pluginManager
|
protected BranchGroup |
rootGroup
|
protected VirtualUniverse |
universe
|
Fields inherited from class syn3d.nodes.SceneNode |
---|
anonymousSceneNumber, dirtyNodes, fileName, FLY_BY_MODE, icon, listeners, REFRESH_PERIOD, refreshPeriod, refreshPeriodChanged, ROTATION_MODE, timer, viewingMode |
Fields inherited from class syn3d.base.ActiveNode |
---|
children, name, parent |
Constructor Summary | |
---|---|
SceneNodeXith3D(ActiveNode parent,
PluginManager pm)
|
Method Summary | |
---|---|
void |
autoZoom()
Auto zooms the scene out of all objects |
void |
changeProjection()
Turns perspective on an off |
void |
doAction(java.lang.Object action)
When the user has selected an action in the list return by getActions(), this method is called. |
java.lang.Object |
get3DObject()
Returns the 3D object that this node refers to. |
java.util.List |
getActions()
Returns a list of possible actions on this node. |
BranchGroup |
getBranchgroup()
|
int |
getLightRotationMode()
|
DirectionalLight[] |
getLights()
|
Locale |
getLocale()
|
VirtualUniverse |
getUniverse()
|
void |
init2DPosition(int posX,
int posY)
Initialize 2D rotation algorithm with the current position as origin. |
boolean |
isVisible()
|
ActiveNode |
pick(int posX,
int posY)
Selects a single pick at the given position. |
void |
remove()
Removes this node from the parent list. |
void |
reset()
Reset all values to default |
void |
rotate2D(int newX,
int newY)
Does a rotation of the scene according to moves in a 2D coordinate system. |
void |
sceneChanged(SceneNode scene)
|
void |
setVisible(boolean status)
|
void |
showLightVector(float x,
float y,
float z)
|
java.util.ArrayList |
toggleAllPicks(int posX,
int posY)
Adds or removes all picks between the given position and the last position, to the selected objects. |
java.util.ArrayList |
toggleSinglePick(int posX,
int posY)
Adds or removes a single pick at the given position to the selected objects. |
void |
translate2D(int newX,
int newY)
Does a translation of the scene according to moves in a 2D coordinate system. |
void |
zoom(int zoomIncrement)
Zooms in or out of the scene according to the increment. |
void |
zoom2D(int newX,
int newY)
Uses the 2D increments in position to compute a zoom factor, then zooms the scene accordingly. |
Methods inherited from class syn3d.nodes.SceneNode |
---|
addDirtyNode, addListener, getIcon, getRefreshPeriod, getScene, getViewingMode, notificationEnd, notifyChange, notifyListeners, propagateHighlightEvent, propagateInternalChangeEvent, removeDirtyNode, removeListener, restoreReferences, restoreScene, saveChildren, setRefreshPeriod, setViewingMode |
Methods inherited from class syn3d.nodes.GroupNode |
---|
getScene |
Methods inherited from class syn3d.base.ActiveNode |
---|
addChild, findDescendantOfType, findDescendantOfType, getChildren, getName, getParent, highlight, notifyInternalChange, notifyStructuralChange, propagateAddChildEvent, propagateChangeNameEvent, propagateRemoveChildEvent, propagateStructuralChangeEvent, removeChild, removeNodeTree, removeNodeTreeFrom, setName, setParent, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected VirtualUniverse universe
protected Locale locale
protected BranchGroup rootGroup
protected BranchGroup branchgroup
protected Frame3DXith3D frame
protected DirectionalLight[] lights
protected Shape3D lightVector
protected int lightRotationMode
protected PluginManager pluginManager
Constructor Detail |
---|
public SceneNodeXith3D(ActiveNode parent, PluginManager pm)
Method Detail |
---|
public void remove()
SceneNode
remove
in class SceneNode
public java.lang.Object get3DObject()
ActiveNode
get3DObject
in class ActiveNode
public java.util.List getActions()
ActiveNode
getActions
in class SceneNode
public void doAction(java.lang.Object action)
ActiveNode
doAction
in class SceneNode
action
- An action previously declared by the getActions method.public boolean isVisible()
isVisible
in class SceneNode
public void setVisible(boolean status)
setVisible
in class SceneNode
public BranchGroup getBranchgroup()
public Locale getLocale()
public VirtualUniverse getUniverse()
public DirectionalLight[] getLights()
public int getLightRotationMode()
public void sceneChanged(SceneNode scene)
sceneChanged
in interface SceneChangeListener
public void showLightVector(float x, float y, float z)
public void init2DPosition(int posX, int posY)
SceneNode
init2DPosition
in class SceneNode
public void rotate2D(int newX, int newY)
SceneNode
rotate2D
in class SceneNode
newX
- The new X position in 2D, typically a mouse positionnewY
- The new Y position in 2D, typically a mouse positionpublic void translate2D(int newX, int newY)
SceneNode
translate2D
in class SceneNode
newX
- The new X position in 2D, typically a mouse positionnewY
- The new Y position in 2D, typically a mouse positionpublic void zoom(int zoomIncrement)
SceneNode
zoom
in class SceneNode
zoomIncrement
- A value typically 1 or -1, but which can be greater for fast zooms.
Positive values zoom in, negative values zoom out.public void zoom2D(int newX, int newY)
SceneNode
zoom2D
in class SceneNode
newX
- The new X position in 2D, typically a mouse positionnewY
- The new Y position in 2D, typically a mouse positionpublic void changeProjection()
SceneNode
changeProjection
in class SceneNode
public void reset()
SceneNode
reset
in class SceneNode
public void autoZoom()
SceneNode
autoZoom
in class SceneNode
public java.util.ArrayList toggleSinglePick(int posX, int posY)
SceneNode
toggleSinglePick
in class SceneNode
posX
- the 2D X position where to do the pickingposY
- the 2D Y position where to do the picking
ActiveNode.higlight(boolean,Object)
public java.util.ArrayList toggleAllPicks(int posX, int posY)
SceneNode
toggleAllPicks
in class SceneNode
posX
- the 2D X position defining a region with the last position. All objects in this region should be picked.
ActiveNode.higlight(boolean,Object)
public ActiveNode pick(int posX, int posY)
SceneNode
pick
in class SceneNode
posX
- the 2D X position where to do the pickingposY
- the 2D Y position where to do the picking
ActiveNode.higlight(boolean,Object)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |