Nodes/Orion4D_generative_paint/Generative Paint Projects
ComfyUI Node

Generative Paint Projects

A mini Photoshop that lives in your ComfyUI browser tab — no model, no API

By orion4d·Created 4 months ago·Updated 4 months ago· 12
Generative Paint Projects
    • image
    • rgba
    • mask
    project__new__
    project_nameproject
    format_modepreset
    format_preset1:1 — 2048x2048
    width2048
    height2048
    fallback_bgblack

    Orion4D Generative Paint sounds too good to be true until you clock what it actually is: a small layered painting program - brushes, selections, gradients, blend modes, the works - served in a browser tab by ComfyUI itself, with the finished canvas handed back to your graph as a normal image. No API, no key, no model download. The node class is Orion4DGenerativePaintProjects (menu name "Generative Paint Projects", category Orion4D_GenerativePaint), and the "generative" in the name is doing a lot of heavy lifting: there's no diffusion here, just a very opinionated paint app bolted onto a node.

    Why you'd reach for it: the annoying step in any masked workflow is leaving ComfyUI to draw the mask. You either alt-tab into Krita or Photoshop, or wrestle with the built-in mask-paint overlay, then import a PNG back. This node keeps the whole loop in the browser. Draw a base composition or a precise mask, save, and the node re-reads the project file and emits it as outputs your graph can eat.

    What it actually does

    Two jobs, one node. First, it's a project manager and live preview for the painting app itself. The editor lives in the pack's web/ folder and is served by ComfyUI's own HTTP server at /generative_paint_projects. The node's Open App button opens that URL in a new tab - pass it the project you're on, get a full-screen canvas. When you hit the commit check in the editor, it writes the project to projects/<name>.png plus a <name>.gpaint.json sidecar holding every layer, palette, and canvas setting.

    Second, when the graph runs, it loads that PNG and returns three outputs: image (RGB, flattened onto your chosen background), rgba (same pixels, transparency preserved), and mask (derived from the alpha channel).

    That mask output is the sneaky good part. Because you build it with real selection tools - lasso, rectangle, ellipse, add/subtract with Alt and Ctrl - you get a genuinely cut-out mask, not a fuzzy hand-painted blob. Wire it into a Set Mask or masked-inpaint conditioning and you're doing deliberate masked editing (the thing the KB's inpainting doc still says masks uniquely own: bit-identical unmasked pixels and a denoise dial) instead of hoping the model guesses the region.

    The inputs that matter

    Seven required inputs; you'll actually touch four:

    • project - dropdown of __new__ plus every saved project. Pick __new__ to start fresh.
    • project_name - what the project saves as. Letters, numbers, dashes, underscores; anything else gets sanitized.
    • format_mode / format_preset / width / height - canvas size for new projects. Presets cover 1:1 2048, 16:9 3840×2160, 9:16, 4:5, and 3:2; manual lets you set anything from 64 to 8192.
    • fallback_bg - black, white, or transparent. Only affects the flattened image and the derived mask: it's what transparent pixels get composited onto.

    One intentional gotcha the README calls out: existing projects keep their saved size. Crank the node to 2048×2048 all you like - a 1500×1500 project stays 1500×1500 so you never distort what you already painted.

    Installing it

    It's on ComfyUI Manager (search "Orion4D_generative_paint" or "Generative Paint"), or the manual route:

    cd ComfyUI/custom_nodes
    git clone https://github.com/orion4d/Orion4D_generative_paint
    

    Then restart ComfyUI. That's genuinely it - there's no requirements.txt, no extra Python packages, no model files to fetch. The whole thing runs on Pillow, numpy, and torch, which ComfyUI already ships. The real weight is the ~5,400-line web app the node serves, not any dependency you have to install.

    Common issues

    • Project missing or the node's preview is stale: click Refresh Projects on the node, or restart ComfyUI.
    • The editor looks old: hard-refresh with Ctrl+F5; the browser caches the interface.
    • Projects vanish: they're stored in the pack's projects/ folder. Reinstall or delete the node and they're gone. Back that folder up if you're attached to anything.
    • First-version rough edges (from early users, not just the README): the layers panel is tucked behind an unlabeled tab and hard to find, there's a noticeable lag when a stroke first starts, and custom effects feel clumsy rather than WYSIWYG. It's v1.0 software with real potential - it's just not Photoshop yet.

    Bottom line

    Reach for this whenever you'd otherwise leave ComfyUI to paint something - an inpaint mask, a texture, a rough comp. It's free, dependency-free, and hands back exactly what a masking workflow wants: RGB + RGBA + mask in one run. It won't replace Krita; it's the faster way to stay in the loop. The real cost is learning a UI that's still being polished.

    CategoryOrion4D_GenerativePaint

    Inputs (7)

    NameTypeDefaultDescription
    projectCOMBO__new__2 options: __new__, Generative_Paint
    project_nameSTRINGproject
    format_modeCOMBOpreset2 options: preset, manual
    format_presetCOMBO1:1 — 2048x20485 options: 1:1 — 2048x2048, 16:9 — 3840x2160, 9:16 — 2160x3840, 4:5 — 2160x2700, 3:2 — 3000x2000
    widthINT204864–8192
    heightINT204864–8192
    fallback_bgCOMBOblack3 options: black, white, transparent

    Outputs (3)

    NameTypeDescription
    imageIMAGE
    rgbaIMAGE
    maskMASK