|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--WF3DNode
This class is used to represent a VRML node of any type. A node contains certain fields depending on the node type. See the Nodes package to get a listing of all node types and their corresponding fields.
| Field Summary | |
java.lang.String |
name
The unique user defined name of this node |
int |
type
The type of this node. |
| Method Summary | |
void |
addChild(WF3DNode node)
Adds a node to the children field of this object. |
java.lang.Object |
clone()
Creates and returns a copy of this object. |
WF3DNode[] |
getChildren()
|
WF3DField |
getField(int fieldIndex)
Retrieves a field of this object. |
WF3DNode |
getNode(int fieldIndex)
Retrieves the contained node in the specified field of this object. |
WF3DNode |
getNode(java.lang.String name)
Retrieves the node with the specified name by searching for it in this object's fields and sub-nodes. |
WF3DNode |
getParent()
|
WF3DNode |
makeUSEInstance()
Creates and returns a copy of this object. |
void |
move(float moveX,
float moveY,
float moveZ)
Moves the object and all its sub-objects relative to the parent object. |
void |
removeChild(WF3DNode node)
Removes a node from the children field of this object. |
void |
rotN(float x,
float y,
float z,
float Nx,
float Ny,
float Nz,
float angle)
Rotates the object relative the parent object. |
void |
scale(float scaleX,
float scaleY,
float scaleZ)
Scales the object and all its sub-objects. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public java.lang.String name
public int type
| Method Detail |
public java.lang.Object clone()
clone in class java.lang.Objectpublic WF3DNode makeUSEInstance()
public WF3DNode[] getChildren()
public WF3DNode getParent()
public void addChild(WF3DNode node)
node - the node to be added to the children field.public void removeChild(WF3DNode node)
node - the node to be removed from the children field.public WF3DNode getNode(int fieldIndex)
fieldIndex - the index of the field to be accessed.
public WF3DField getField(int fieldIndex)
transformNode.getField (Nodes.Transform.translation);
fieldIndex - the index of the field to be accessed
public WF3DNode getNode(java.lang.String name)
name - The name of the node to retrieve
public void scale(float scaleX,
float scaleY,
float scaleZ)
scaleX - the scaling along the x axisscaleY - the scaling along the y axisscaleZ - the scaling along the z axis
public void move(float moveX,
float moveY,
float moveZ)
moveX - the movement along the x axismoveY - the movement along the y axismoveZ - the movement along the z axis
public void rotN(float x,
float y,
float z,
float Nx,
float Ny,
float Nz,
float angle)
x - the x coordinate of the point around which the rotation will be performedy - the y coordinate of the point around which the rotation will be performedz - the z coordinate of the point around which the rotation will be performedNx - the x coordinate of the normalised rotation vectorNy - the y coordinate of the normalised rotation vectorNz - the z coordinate of the normalised rotation vectorangle - the rotation angle, in radians (1 radian = PI/180 degrees)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||