Node
Overview
Node is a class in Aspose.3D FOSS for .NET.
Inherits from: SceneObject.
Represents an element in the scene graph.
This class provides 26 methods for working with Node objects in .NET programs.
Available methods include: A3DObject, Accept, AddChildNode, AddEntity, CreateChildNode, EvaluateGlobalTransform, FindProperty, GetBoundingBox, GetChild, GetEntity, GetProperty, Merge, and 7 additional methods.
All public members are accessible to any .NET application after installing the Aspose.3D FOSS for .NET package.
Properties: AssetInfo, ChildNodes, Entities, Entity, Excluded, GlobalTransform, and 9 more.
Properties
| Name | Type | Access | Description |
|---|---|---|---|
AssetInfo | AssetInfo? | Read/Write | Per-node asset info |
Visible | bool | Read/Write | Gets or sets to show the node |
ChildNodes | IList<Node> | Read | Gets the children nodes. |
Entity | Entity? | Read/Write | Gets or sets the first entity attached to this node, if sets, will clear other entities. |
Excluded | bool | Read/Write | Gets or sets whether to exclude this node and all child nodes/entities during exporting. |
Entities | IList<Entity> | Read | Gets all node entities. |
MetaDatas | IList<CustomObject> | Read | Gets the meta data defined in this node. |
Materials | IList<Shading.Material> | Read | Gets the materials associated with this node. |
Material | Shading.Material? | Read/Write | Gets or sets the first material associated with this node, if sets, will clear other materials |
ParentNode | Node? | Read/Write | Gets or sets the parent node. |
Transform | Transform | Read | Gets the local transform. |
GlobalTransform | GlobalTransform | Read | Gets the global transform. |
Scene | Scene | Read | Gets the scene that this object belongs to |
Name | string | Read/Write | Gets or sets the name. |
Properties | PropertyCollection | Read | Gets the collection of all properties. |
Methods
| Signature | Description |
|---|---|
Node() | Initializes a new instance of the Node class. |
Node(name: string) | Initializes a new instance of the Node class. |
Node(name: string, entity: Entity) | Initializes a new instance of the Node class. |
CreateChildNode() | Creates a child node |
CreateChildNode(nodeName: string) | Create a new child node with given node name |
CreateChildNode(entity: Entity) | Create a new child node with given entity attached |
CreateChildNode(nodeName: string, entity: Entity) | Create a new child node with given node name |
CreateChildNode(nodeName: string, entity: Entity, material: Shading.Material) | Create a new child node with given node name, and attach specified entity and a material |
AddChildNode(node: Node) | Add a child node to this node |
AddEntity(entity: Entity) | Add an entity to the node. |
Merge(node: Node) | Detach everything under the node and attach them to current node. |
EvaluateGlobalTransform(withGeometricTransform: bool) | Evaluate the global transform, include the geometric transform or not. |
GetChild(index: int) | Gets the child node at specified index. |
GetChild(nodeName: string) | Gets the child node with the specified name |
Accept(visitor: NodeVisitor) | Walks through all descendant nodes(including the current node) and call the visitor with the node. |
GetBoundingBox() | Calculate the bounding box of the node |
SelectSingleObject(path: string) | Select single object under current node using XPath-like query syntax. |
SelectObjects(path: string) | Select multiple objects under current node using XPath-like query syntax. |
ToString() | Gets the string representation of this node. |
GetEntity() | Gets the first entity that matches the specified type T. |
SceneObject(name: string) | Initialize an SceneObject with a default name |
A3DObject() | Initializes a new instance of the A3DObject class with no name. |
RemoveProperty(property: Property) | Removes a dynamic property. |
GetProperty(property: string) | Get the value of specified property |
SetProperty(property: string, value: object?) | Sets the value of specified property |
FindProperty(propertyName: string) | Finds the property. |