Node class

Node class

Represents an element in the scene graph. A scene graph is a tree of Node objects. The tree management services are self contained in this class. Note the Aspose.3D SDK does not test the validity of the constructed scene graph. It is the responsibility of the caller to make sure that it does not generate cyclic graphs in a node hierarchy. Besides the tree management, this class defines all the properties required to describe the position of the object in the scene. This information include the basic Translation, Rotation and Scaling properties and the more advanced options for pivots, limits, and IK joints attributes such the stiffness and dampening. When it is first created, the Node object is “empty” (i.e: it is an object without any graphical representation that only contains the position information). In this state, it can be used to represent parents in the node tree structure but not much more. The normal use of this type of objects is to add them an entity that will specialize the node (see the “Entity”). The entity is an object in itself and is connected to the the Node. This also means that the same entity can be shared among multiple nodes. Camera, Light, Mesh, etc… are all entities and they all derived from the base class Entity.

Inheritance: NodeSceneObjectA3DObject

The Node type exposes the following members:

Constructors

ConstructorDescription
initInitializes a new instance of the Node class.
initInitializes a new instance of the Node class.
initInitializes a new instance of the Node class.

Properties

PropertyDescription
nameGets or sets the name.
propertiesGets the collection of all properties.
sceneGets the scene that this object belongs to
asset_infoPer-node asset info
visibleGets or sets to show the node
child_nodesGets the children nodes.
entityGets or sets the first entity attached to this node, if sets, will clear other entities.
excludedGets or sets whether to exclude this node and all child nodes/entities during exporting.
entitiesGets all node entities.
meta_datasGets the meta data defined in this node.
materialsGets the materials associated with this node.
materialGets or sets the first material associated with this node, if sets, will clear other materials
parent_nodeGets or sets the parent node.
transformGets the local transform.
global_transformGets the global transform.

Methods

MethodDescription
remove_propertyRemoves a dynamic property.
remove_propertyRemove the specified property identified by name
create_child_nodeCreates a child node
create_child_nodeCreate a new child node with given node name
create_child_nodeCreate a new child node with given entity attached
create_child_nodeCreate a new child node with given node name
create_child_nodeCreate a new child node with given node name, and attach specified entity and a material
get_childGets the child node at specified index.
get_childGets the child node with the specified name
get_propertyGet the value of specified property
set_propertySets the value of specified property
find_propertyFinds the property.
It can be a dynamic property (Created by CreateDynamicProperty/SetProperty)
or native property(Identified by its name)
mergeDetach everything under the node and attach them to current node.
evaluate_global_transformEvaluate the global transform, include the geometric transform or not.
get_bounding_boxCalculate the bounding box of the node
add_entityAdd an entity to the node.
add_child_nodeAdd a child node to this node
select_single_objectSelect single object under current node using XPath-like query syntax.
select_objectsSelect multiple objects under current node using XPath-like query syntax.

See Also