Nodes/ComfyUI-JH-PixelPro/LUT Export (.cube)
ComfyUI Node

LUT Export (.cube)

Bake Any ComfyUI Grade Into a .cube File

By jetthuangai·Created 5 months ago·Updated 4 months ago· 5
LUT Export (.cube)
  • image
  • path
level8
filenamepack_lut.cube
titleJHPixelPro LUT

JHPixelProLUTExport turns a graded image into a portable Adobe Cube 1.0 (.cube) LUT file - the format DaVinci Resolve, Premiere, OBS, and OCIO all read. You develop a color grade inside ComfyUI once, export it as a .cube, and apply it anywhere. That's the whole pitch, and it's a good one.

The trick is the upstream. You don't feed this node your actual photo. You feed it a HALD identity image - a special color chart that encodes the entire color cube as a single image - after it's passed through your grade chain. The pack's JHPixelProHALDIdentity generates it (level 8 → a 512×512 chart sampling 64³ colors). The wiring is: HALD Identity → your color-only nodes (tone curve, LUT, saturation, whatever) → this export node. Whatever color math the grade applied to the HALD chart gets baked into the .cube.

One hard rule: only wire color-only operations between HALD Identity and this node. Spatial stuff - sharpening, denoise, face work, lens distortion - will not linearize into a 3D LUT. That's the main thing that trips people up, and it's not a bug; it's what the format is.

Inputs:

  • image - the graded HALD from upstream.
  • level - must match the HALD level used to generate the image (default 8). A mismatch raises a ValueError.
  • filename - output path, relative to ComfyUI/output/ or absolute. .cube is auto-appended if missing; existing files are overwritten.
  • title - the TITLE header shown in DaVinci and Premiere when browsing LUTs.

Output is a single STRING: the absolute path to the written file. Pipe it into a ShowText node if you want it visible on the canvas.

Install is the shared pack install:

cd ComfyUI/custom_nodes
git clone https://github.com/jetthuangai/ComfyUI-JH-PixelPro.git
cd ComfyUI-JH-PixelPro
pip install -r requirements.txt

Restart ComfyUI and it appears under ComfyUI-JH-PixelPro/color. Or use ComfyUI Manager → search "ComfyUI-JH-PixelPro". Requirements: kornia ≥ 0.7.0, OpenCV ≥ 4.8, SciPy ≥ 1.10, Python ≥ 3.10, and ComfyUI ≥ 0.43.x.

Troubleshooting: the level mismatch is the classic error - always wire HALD Identity's level output straight into this node's level input so they can't drift apart. The parent directory of your filename must already exist; the node deliberately won't mkdir for you (you get an OSError, which is the pack being tidy on purpose). Watch memory at high HALD levels: level 12 is a 1728² image, ~36 MB in float32 before your chain inflates it. And it's RGB-only with no alpha - a 3D LUT format limitation, not a bug.

Verdict: this is the node that makes the pack's grading worth anything outside ComfyUI. Develop a look once, ship it to Resolve, never touch the graph again.

CategoryComfyUI-JH-PixelPro/color

Inputs (4)

NameTypeDefaultDescription
imageIMAGE
levelINT82–16HALD level L — MUST match the level used by the upstream HALD Identity node. Image H==W==L³ is validated; mismatch raises ValueError.
filenameSTRINGpack_lut.cubeFilename (relative to ComfyUI output/) or absolute path. '.cube' extension auto-appended if missing. Existing files are overwritten.
titleSTRINGJHPixelPro LUTAdobe Cube TITLE header metadata — shown by DaVinci Resolve, Premiere and other LUT tools when browsing cube files.

Outputs (1)

NameTypeDescription
pathSTRING