Skip to content

Building a scene

What the Pathtracer renders

The Pathtracer renders the operators named in its Geometry / Lights parameter, looked up in the network it sits in. The default * takes everything beside it; a pattern such as PT_GEO* PT_LIGHT1 takes only those.

It renders three kinds of operators:

  • PT GEO components: geometry with a material, placed and moved like a Geometry COMP.
  • PT LIGHT components: area lights.
  • POPs: plain geometry, rendered with a default white material, or with the materials and attributes it already carries.

An operator whose Render flag is off is left out, and so is a PT GEO or PT LIGHT whose Render parameter is off. That makes it easy to switch objects on and off without rewiring.

Placing geometry with PT GEO

Wire any POP into a PT GEO. The PT GEO places it in the scene with its Xform page, exactly like a Geometry COMP: translate, rotate and scale it, parent it to another object, make it look at something, or move it along a path. Its Material parameter picks the PT MAT to render it with.

Use one PT GEO per object you want to move on its own. To render many copies of something, build them in POPs first (for example with a Copy POP) and wire the result into one PT GEO.

Several materials on one object

A PT MAT also has an input and an output. Geometry wired through a PT MAT takes that material. Wire the parts of an object through different PT MATs, merge them, and wire the result into a PT GEO whose Material is empty: each part keeps its own material.

Attributes the Pathtracer reads

The Pathtracer uses these attributes when the geometry has them:

Attribute Used for
N Normals: smooth shading of curved surfaces.
Tex Texture coordinates, for textures on materials and lights.
Color, Emit, Metallic, Roughness, Ior, Clearcoat, Clearcoattint, Transparency, Absorption, Dispersion Material values that change across a surface, when the material's Attributes page asks for them (see Materials).

Missing normals are computed for you.

Keep normals and texture coordinates on the same kind of element

The Pathtracer reads each attribute from one kind of element (points, vertices or primitives) for the whole scene. If some inputs have N or Tex on points and others on vertices, some objects lose their texture or shade wrongly, and the Pathtracer shows a warning such as Point attribute N used as but not defined on all inputs. TouchDesigner's own POPs differ here: the Sphere POP has point normals and vertex texture coordinates, the Grid POP has both on points. Convert them to the same kind before they reach the Pathtracer, for example to vertex attributes with an Attribute Convert POP that deletes the originals. See Troubleshooting.

Moving objects

Anything can move: PT GEO transforms, animated POPs, the camera. The Pathtracer notices changes on its own. With the Average method each change starts the image over; the other methods carry on (see Denoising).

For moving or deforming objects, turn on Use Velocity on the Pathtracer's Denoising page, so the denoisers can follow them.

Heavy scenes that don't change

Lock Input freezes the scene as it is. Changes to the geometry no longer reach the render until you turn it off again, and the Pathtracer no longer spends time collecting the geometry.