# HueCorrect

> Curves over hue (red, yellow, green, cyan, blue, magenta) that change saturation, luminance and red / green / blue gain, and suppress a channel (r_sup / g_sup / b_sup) for the hues you choose, e.g.

Curves over hue (red, yellow, green, cyan, blue, magenta) that change saturation, luminance and red / green / blue gain, and suppress a channel (r_sup / g_sup / b_sup) for the hues you choose, e.g. to take spill out of one hue range only. A grey pixel has no hue, so it reads the curves at the red end only.

| Node | HueCorrect |
|---|---|
| Menu | Color › HueCorrect |
| **Names in each format** | |
| .oink comp (JSON) | `"type": "OC_N_huecorrect"` |
| .nk script | `HueCorrect` ([how .nk import works](/docs/nuke-users/nk-import)) |
| Python | `nuke.createNode("HueCorrect")` |
| Assistant (MCP) | `create_node(type="HueCorrect")` |
| Tab search | `huecorrect`, or its initials `hc` |

![HueCorrect properties](/shots/nodes/huecorrect@2x.webp)

## Inputs and outputs

| Port | Name | Type |
|---|---|---|
| input 0 | Image | image |
| input 1 | mask | image |
| output 0 | Image | image |

## Knobs

Panel tab **HueCorrect**, in panel order.

| Knob | Label | Type | Default | Range / values | .nk knob | Description |
|---|---|---|---|---|---|---|
| `channels` | channels | menu | `rgb` | rgba, rgb, alpha, all, none |  | Layer the op applies to: rgb, rgba, alpha, all, none, <layer> or <layer>.<ch> |
| `hue` | hue | curves | `{sat {} lum {} red {} green {} blue {} r_sup {} g_sup {} b_sup {} sat_thrsh {}}` |  |  | the curve set: sat, lum, red, green, blue, r_sup, g_sup, b_sup, sat_thrsh (pixels less |
| `mask_channel` | mask | menu | `none` | none, rgba.alpha, rgba.red, rgba.green, rgba.blue |  | Mask channel, e.g. rgba.alpha (none = no mask) |
| `inject` | inject | bool | `false` |  |  | Copy the mask into mask.a for nodes downstream |
| `invert_mask` | invert | bool | `false` |  | `invert_mask` |  |
| `fringe` | fringe | bool | `false` |  |  | Only apply the effect at the edges of the mask |
| `unpremult` | (un)premult by | menu | `none` | none, rgba.alpha |  |  |
| `invert_unpremult` | invert | bool | `false` |  |  | (Un)premultiply by 1 - alpha |
| `enable_mix_luminance` | mix luminance | bool | `true` |  | `enable_mix_luminance` |  |
| `mix_luminance` | mix luminance | float | `0` | 0 to 1 | `mix_luminance` |  |
| `mix` | mix | float | `1` | 0 to 1 | `mix` |  |

### Other knobs (Python, .nk and the assistant; not on the panel)

| Knob | Label | Type | Default | Range / values | .nk knob | Description |
|---|---|---|---|---|---|---|
| `gl_color` | Viewer Controls Color | float ×3 | `0, 0, 0` | 0 to 1 |  |  |
| `postage_stamp_frame` | Static Frame | int | `1` | -2147483648 to 2147483647 |  |  |
| `lifetimeStart` | Lifetime Start | int | `0` | -2147483648 to 2147483647 |  |  |
| `lifetimeEnd` | Lifetime End | int | `100` | -2147483648 to 2147483647 |  |  |
| `useLifetime` | Use Lifetime | boolean | `false` |  |  |  |
| `cached` | Cached | boolean | `false` |  |  |  |
| `bookmark` | Bookmark | boolean | `false` |  |  |  |
| `dope_sheet` | Dope Sheet | boolean | `false` |  |  |  |
| `clone_group` | Clone Group | string |  |  |  |  |
| `link_source` | Link Source | string |  |  |  |  |
| `link_overrides` | Link Overrides | string |  |  |  |  |
| `split_views` | Split Views | string |  |  |  |  |


---
Sources: opencomp_core/nodes/keyer/despill.py, opencomp_electron/src/components/properties/knobSchema.ts, opencomp_core/nodes/help/huecorrect.md, opencomp_core/nk/mapping.py
