x3d_move_node
Reparent a node in an X3D scene graph by moving it from its current parent to a new parent, preventing cycles.
Instructions
Reparent a node from its current parent to a new parent in the scene graph.
Detaches the node (by DEF name) from its current location and appends it
as a child of the new parent. Detects and prevents cycles.
Args:
x3d_source: Complete X3D XML document string or file path.
def_name: DEF name of the node to move.
new_parent_def: DEF name of the new parent node. Leave empty to move
to be a direct child of <Scene>.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| def_name | Yes | ||
| x3d_source | Yes | ||
| new_parent_def | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |