Apply LUT
apply_lutApply a color LUT to a TOP in TouchDesigner with strength and bypass controls. Supports Cube, 3DL, CC, CCC files and image-based LUTs via OCIO or fallback paths.
Instructions
Apply a colour Look-Up Table (LUT) to an existing TOP inside a self-contained baseCOMP. Prefers an OpenColorIO TOP for .cube/.3dl/.cc/.ccc files; falls back to a Movie File In + Lookup TOP for image LUTs or when OCIO is unavailable. A .cube file with no OCIO is parsed in Python into a Script TOP ramp. Exposes Strength and Bypass controls on a custom page. Pass source_path to grade an existing TOP, or omit it for a standalone preview on a grey Constant TOP.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lut_path | Yes | Absolute path to the LUT file. Accepts `.cube`, `.3dl`, `.cc`, `.ccc` (routed to OpenColorIO when available, otherwise parsed in Python for `.cube` or loaded via Movie File In for image-format LUTs). PNG/EXR/etc. always use the Movie File In + Lookup TOP fallback. | |
| source_path | No | Absolute TD path of the existing TOP to grade (e.g. '/project1/render1'). TD wires can't cross COMPs, so the source is pulled in via a Select TOP referencing the absolute path. When omitted, a Constant TOP (mid-grey, 1280×720) is created as a stand-in so the chain cooks and previews standalone. | |
| ocio_config_path | No | Optional absolute path to an OCIO config file (`.ocio`). Only used when the OCIO branch is taken. | |
| strength | No | Blend amount between source (0 = untouched) and graded output (1 = full LUT). Drives the Cross TOP crossfade parameter. | |
| bypass | No | When true, forces the Cross TOP crossfade to 0 so the source passes through unchanged. Also exposed as a toggle on the custom page. | |
| prefer | No | Branch selection. `auto` probes OpenColorIO availability at runtime and uses it for `.cube`/`.3dl`/`.cc`/`.ccc` files, falling back to the Lookup TOP path for images. `ocio` forces the OCIO branch. `lookup` forces the Movie File In + Lookup TOP path even when OCIO is available. | auto |
| expose_controls | No | When true, appends custom-page parameters Strength (float 0..1) and Bypass (toggle) on the container COMP and binds them to the Cross TOP crossfade. | |
| parent_path | No | Parent COMP network where the LUT chain container is created. | /project1 |
| container_name | No | Base name for the container COMP (a numeric suffix is auto-applied by TD). | apply_lut |