x3d_remove_node
Delete a node and its children from an X3D scene by DEF name or type/index, and get the modified X3D XML.
Instructions
Remove a node (and its children) from an X3D scene.
Identifies the target by DEF name, or by node_type + index. Returns
the modified X3D XML document with the node removed.
Args:
x3d_source: Complete X3D XML document string or file path.
def_name: DEF name of the node to remove. Takes precedence over node_type.
Use x3d_list_defs to see available names.
node_type: Node type to remove (e.g., "DirectionalLight", "Transform").
Combined with index to select which instance.
index: 0-based index when removing by node_type. Default 0 (first match).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| index | No | ||
| def_name | No | ||
| node_type | No | ||
| x3d_source | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |