How-To#
One page per thing a node or a graph can do. These are not written to be read in order. Each page states its goal, what it assumes you already have, the shape of the solution, how to confirm it worked, and what to check when it does not.
Both languages appear on the same page. Where CUDA and Slang differ, each is shown in its own tab rather than in a separate chapter. For the surface each task draws on, refer to Reference.
Write a Node#
Task |
Goal |
|---|---|
Give a node a number, vector or matrix authored in USD, and read it in the GPU code. |
|
Decide whether a resource is texture-backed or buffer-backed, and bind it correctly. |
|
Get a lookup table, a filter kernel or any authored array onto the GPU. |
|
Decide how many GPU threads run, and over what. |
|
Build the GPU code with your own toolchain, or split it across files. |
Wire a Graph#
Task |
Goal |
|---|---|
Feed one node’s output straight into the next, without publishing the intermediate. |
|
Feed one node’s output to several consumers, or several producers into one node. |
|
Decide what a graph exposes to the rest of the pipeline, and get it back on the host. |
|
Read an AOV produced by a different RenderProduct, or drive several products at once. |
|
Build an AOV out of authored values alone, with no AOV coming in. |
|
Get a common operation without writing any GPU code. |
Across Frames#
Task |
Goal |
|---|---|
Let a node read what it wrote last frame. |
|
Read an AOV as it was N frames ago. |
|
Compute something once instead of every frame. |
|
Retune or rewire a graph without reloading the scene. |
Reach Beyond an AOV#
Task |
Goal |
|---|---|
Consume a lidar or radar point cloud in a node. |
|
Have a node render the scene itself rather than transform an AOV. |
Slang Specifics#
Task |
Goal |
|---|---|
Place resources into specific descriptor spaces, and state a constant buffer’s layout. |