Wrangle
Advanced VEX interface. Emit attributes, define gates, or prototype effectors directly into the Natsura graph.
The Wrangle node provides a VEX interface into the procedural graph. It runs on active growth tips during simulation (not on static geometry) and is the primary way to create custom attributes for mappings, gates, and effectors. It can sample external Houdini geometry (SDFs, attributes) to guide growth. Attributes created here flow upstream to parent nodes and sockets: set f@my_bend in a Wrangle and you can use it in a Map connected to a Grow node's Pitch input.
Inputs
| Input | Description |
|---|---|
| Input 0: Graph | The Natsura graph. Wrangle runs on the active tips. |
| Input 1: Skeleton (optional) | The full simulated skeleton (if enabled). Useful for nearpoints() queries. |
| Input 2+: Geometry (optional) | Standard Houdini geometry or volumes for environment sampling. |
Attributes
Built-in attributes available for reading and writing:
| Attribute | Description |
|---|---|
id | Built-in attribute available for reading and writing. |
parent_id | Built-in attribute available for reading and writing. |
generation | Built-in attribute available for reading and writing. |
u | Built-in attribute available for reading and writing. |
age | Built-in attribute available for reading and writing. |
width | Built-in attribute available for reading and writing. |
internode_length | Built-in attribute available for reading and writing. |
P | Built-in attribute available for reading and writing. Modifying it affects growth direction. |
N | Built-in attribute available for reading and writing. Modifying it affects growth direction. |
up | Built-in attribute available for reading and writing. Modifying it affects growth direction. |
Custom attributes (f@density, i@kill, anything else) can be created and used downstream in Map or Switch.
Outputs
| Output | Description |
|---|---|
| Output: Graph | The modified graph. |
Parameters
Attributes
| Parameter | Description |
|---|---|
| Graph Attributes | Registers new attributes so they appear in Natsura's UI (dropdowns, inputs). Manages attributes available for use in custom growth logic. |
| Attribute | Name of the attribute being manipulated. |
| Value | Value assigned to the attribute. |
| Mapped Attribute | References external mappings or relationships. |
VEX Code
| Parameter | Description |
|---|---|
| Graph Snippet | The VEX code to execute. Write VEX for dynamic evaluations, custom solvers, environmental responses, or attribute-driven adjustments. |
Connections
| Parameter | Description |
|---|---|
| Connect Main | Feeds the simulation output back into Input 1 for self-queries. Toggle this for main graph connections. |
Notes
- Wrangle requires familiarity with VEX scripting to use well.
- Runs within the solver loop on active growth tips, not as a standard SOP operation.
- Attributes created here are available to upstream nodes via inputs and mappings.
See also: Simulation concept · Custom VEX · Map · Switch