convert_color
Convert RGB hex or [r,g,b] colors between a viewer display transform or OCIO colorspace and a target working space using Nuke's OCIO config.
Instructions
Convert an RGB colour with the script's own OCIO config, computed by Nuke. color: "#rrggbb" or [r, g, b]. source "display" (default) means "as it looks on screen through the Viewer's view transform" so the result, put in a Constant, displays as that hex. Otherwise give an OCIO colourspace/role (e.g. "sRGB - Texture" for a plain sRGB-encoded value). target defaults to the working space ("scene_linear").
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"color": "<color>"
},
"name": "convert_color"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| view | No | ||
| color | Yes | ||
| source | No | display | |
| target | No | scene_linear | |
| display | No |