Nuke Image Import
Bring a plate or render from Nuke into ComfyUI
- image
- mask
- payload_json
- asset_path
- summary_json
The compositor's handoff
Compositors live in Nuke; the interesting generative stuff increasingly lives in ComfyUI. MKRNukeImageImport is the node that lets the two talk: it takes a payload describing an image asset from a Nuke-side add-on and loads it into the graph as a proper IMAGE tensor, so a plate, a render, or a specific frame can be dropped into a ComfyUI workflow without a manual "save file, drag file in" dance.
It's part of MKRShift_Nodes, the pack by Cris K B that ships per-DCC add-on scaffolds under addons/ (Nuke included). This node is structurally identical to the Maya, Blender, Photoshop, and Fusion360 image-import siblings - same shared code, different host label. Learn one, you've learned them all.
How it works
Payload in, pixels out. The required input is payload_json - the JSON packet from the Nuke add-on describing the image asset (its mkrshift_nuke_image_v1-style payload with a path). There's also an optional preferred_slot, which matters when one payload references several candidate images and you want a specific one.
The node parses the payload, finds the image path, loads it from disk into an IMAGE tensor (with a MASK output if the file has an alpha channel), and returns everything else you need alongside. If no valid path exists in the payload, it raises - loudly, rather than handing you a blank image you'll blame yourself for later.
The outputs
Five:
image(IMAGE) andmask(MASK) - standard types, so they plug into any stock ComfyUI node. This is the whole point of the import nodes vs. the pack's custom media types: bytes in, normal types out.payload_json- the original payload echoed through, so metadata doesn't get dropped on the floor.asset_path- the file that was actually loaded.summary_json- host, dimensions, candidate count, warnings.
Install and gotchas
cd ComfyUI/custom_nodes
git clone https://github.com/criskb/MKRShift_Nodes
Restart, or install "MKRShift Nodes" via ComfyUI Manager. No pip dependencies, no models, no ffmpeg needed for the import itself.
Two honest caveats. One: it reads what the payload tells it to - the pack ships the Nuke add-on scaffold that builds correct payloads, and hand-authoring them works, but the schema is yours to keep straight. Two: this is file-based handoff, not a live socket into Nuke. If your dream is "press render in Nuke, watch it appear in ComfyUI," that's the transport-plan lane (MKRAddonEndpointPlan and friends), which is a real but more involved setup. For the everyday "send a frame to the graph, do the generative thing, send it back" loop, this node is the first half and it's dead simple.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| payload_json | STRING | — | |
| preferred_slotopt | STRING | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| mask | MASK | — |
| payload_json | STRING | — |
| asset_path | STRING | — |
| summary_json | STRING | — |