Nodes/Comfypencil/Comfy Pencil Receive Preview
ComfyUI Node

Comfy Pencil Receive Preview

Comfy Pencil Receive Preview

By criskb·Created 6 months ago·Updated 5 months ago· 1
Comfy Pencil Receive Preview
  • document
  • image
  • document
  • image
  • status
resize_modefit

Comfy Pencil Studio paints; everything else in your graph reacts. This node is the wire that sends the reaction back into the studio. Connect a PENCIL_DOCUMENT and an IMAGE from any downstream branch, and the node stores that image as the studio's split-view preview - so you can paint on one side of the screen while watching what your img2img, ControlNet, or upscaling branch does with your work on the other. Live.

That's the whole pitch, and it's the difference between ComfyPencil feeling like a demo and feeling like a tool. The workflow loop looks like this: Studio's image → sampler / img2img / whatever branch you're testing → Comfy Pencil Receive Preview → enable Split in the studio. Paint a stroke, run the graph, and the processed result appears beside your canvas instead of requiring you to alt-tab and squint at a preview node.

Mechanically it's a pass-through with a side effect. The node resolves the document, resizes the incoming image to the document dimensions according to resize_mode (fit letterboxes, fill covers and crops, stretch distorts to fill), and saves it to a split-preview slot keyed by the document's id and preview key. Then it hands the same document and image back out untouched, plus a status string that tells you what happened.

Inputs: document, image, resize_mode. Outputs: document (pass-through), image (pass-through), status.

The status output is where the node tells you when you've set it up wrong. If the document has no stable id yet, you get: "Split preview skipped. Open the studio once so the receiver has a stable target." That's not a cryptic error - it's the fix, in plain English. The studio assigns a stable id the first time you open the document, so do that before wiring up the receiver and expecting results.

Two things worth knowing. First, this node doesn't render or transform anything; it's plumbing, so don't expect it to improve or alter the image it receives. Second, keep in mind the pack's known limitation: the studio's browser preview and the backend render are close but not pixel-identical, and the split preview is exactly the kind of place you'll notice that. It's a live reference, not a pixel-perfect match.

Install matches the rest of the pack:

cd ComfyUI/custom_nodes
git clone https://github.com/criskb/Comfypencil ComfyPencil

Restart ComfyUI and hard-refresh the browser. No model downloads, no API keys, no extra Python dependencies beyond ComfyUI's bundled stack, and the pack targets ComfyUI >= 0.16.0. If you're new to the pack, this node and the Studio node are the two to start with - together they're the core of the whole idea.

Categorycomfypencil/studio

Inputs (3)

NameTypeDefaultDescription
documentPENCIL_DOCUMENT
imageIMAGE
resize_modeCOMBOfit3 options: fit, fill, stretch

Outputs (3)

NameTypeDescription
documentPENCIL_DOCUMENT
imageIMAGE
statusSTRING