BenQ Mobile

javax.microedition.m3g
Class Node

java.lang.Object
  extended byjavax.microedition.m3g.Object3D
      extended byjavax.microedition.m3g.Transformable
          extended byjavax.microedition.m3g.Node
Direct Known Subclasses:
Camera, Group, Light, Mesh, Sprite3D

public abstract class Node
extends Transformable

An abstract base class for all scene graph nodes. There are five different kinds of nodes: - Camera defines the projection from 3D to 2D, as well as the position of the viewer in the scene. - Mesh defines a 3D object, consisting of triangles with associated material properties. - Sprite3D defines a screen-aligned 2D image with a position in 3D space. - Light defines the position, direction, color and other attributes of a light source. - Group serves as a root for scene graph branches.


Field Summary
static int NONE
          Specifies for the setAlignment method that no alignment should be done for the specified axis.
static int ORIGIN
          Specifies the origin of the reference node as an orientation reference for the setAlignment method.
static int X_AXIS
          Specifies the X axis of the reference node as an orientation reference for the setAlignment method.
static int Y_AXIS
          Specifies the Y axis of the reference node as an orientation reference for the setAlignment method.
static int Z_AXIS
          Specifies the Z axis of the reference node as an orientation reference for the setAlignment method.
 
Method Summary
 void align(Node reference)
          Applies alignments to this Node and its descendants.
 float getAlphaFactor()
          Retrieves the alpha factor of this Node.
 Node getParent()
          Returns the scene graph parent of this node.
 int getScope()
          Retrieves the scope of this Node.
 boolean getTransformTo(Node target, Transform transform)
          Gets the composite transformation from this node to the given node.
 boolean isPickingEnabled()
          Retrieves the picking enable flag of this Node.
 boolean isRenderingEnabled()
          Retrieves the rendering enable flag of this Node.
 void setAlignment(Node zRef, int zTarget, Node yRef, int yTarget)
          Sets this node to align with the given other node(s), or disables alignment.
 void setAlphaFactor(float alphaFactor)
          Sets the alpha factor for this Node.
 void setPickingEnable(boolean enable)
          Sets the picking enable flag of this Node.
 void setRenderingEnable(boolean enable)
          Sets the rendering enable flag of this Node.
 void setScope(int scope)
          Sets the scope of this node.
 
Methods inherited from class javax.microedition.m3g.Transformable
getCompositeTransform, getOrientation, getScale, getTransform, getTranslation, postRotate, preRotate, scale, setOrientation, setScale, setTransform, setTranslation, translate
 
Methods inherited from class javax.microedition.m3g.Object3D
addAnimationTrack, animate, duplicate, find, getAnimationTrack, getAnimationTrackCount, getReferences, getUserID, getUserObject, removeAnimationTrack, setUserID, setUserObject
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NONE

public static final int NONE
Specifies for the setAlignment method that no alignment should be done for the specified axis.

See Also:
Constant Field Values

ORIGIN

public static final int ORIGIN
Specifies the origin of the reference node as an orientation reference for the setAlignment method.

See Also:
Constant Field Values

X_AXIS

public static final int X_AXIS
Specifies the X axis of the reference node as an orientation reference for the setAlignment method.

See Also:
Constant Field Values

Y_AXIS

public static final int Y_AXIS
Specifies the Y axis of the reference node as an orientation reference for the setAlignment method.

See Also:
Constant Field Values

Z_AXIS

public static final int Z_AXIS
Specifies the Z axis of the reference node as an orientation reference for the setAlignment method.

See Also:
Constant Field Values
Method Detail

setRenderingEnable

public void setRenderingEnable(boolean enable)
Sets the rendering enable flag of this Node.


setPickingEnable

public void setPickingEnable(boolean enable)
Sets the picking enable flag of this Node.


setScope

public void setScope(int scope)
Sets the scope of this node.


setAlphaFactor

public void setAlphaFactor(float alphaFactor)
Sets the alpha factor for this Node.


isRenderingEnabled

public boolean isRenderingEnabled()
Retrieves the rendering enable flag of this Node.


isPickingEnabled

public boolean isPickingEnabled()
Retrieves the picking enable flag of this Node.


getScope

public int getScope()
Retrieves the scope of this Node.


getAlphaFactor

public float getAlphaFactor()
Retrieves the alpha factor of this Node.


getParent

public Node getParent()
Returns the scene graph parent of this node.


getTransformTo

public boolean getTransformTo(Node target,
                              Transform transform)
Gets the composite transformation from this node to the given node.


align

public final void align(Node reference)
Applies alignments to this Node and its descendants.


setAlignment

public void setAlignment(Node zRef,
                         int zTarget,
                         Node yRef,
                         int yTarget)
Sets this node to align with the given other node(s), or disables alignment.


BenQ Mobile

Copyright © 2006 BenQ Mobile GmbH & Co. OHG or respective copyright owner.
All Rights Reserved.
BenQ Corp. is a trademark licensee of Siemens AG.


For further information about Mobility Toolkit (MTK) visit our Developer Portal.