MorisIppolitoandClaude Opus 4.8 f0f9d15520 Region Stitch: drop dynamic input slots (fix "No link found" error)
Adding/removing variant_i/mask_i input slots at runtime could orphan link
references and throw "No link found in parent graph". The optional inputs are
already declared in Python, so they render statically and are read on execution
regardless — removing the JS makes the node robust (at the cost of always
showing all optional inputs).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-09-11 15:08:30 +02:00
2026-09-11 14:01:23 +02:00
2026-04-19 14:17:54 +02:00
2026-04-19 14:17:54 +02:00
2026-09-11 14:05:13 +02:00

🎨 ComfyUI-Momo-Nodes

Custom nodes for ComfyUI by Momo.

A growing collection of quality-of-life nodes focused on masking, visual editing, and workflow improvements.


Nodes

RGB Mask Editor ✏️

image

An interactive visual editor for creating RGB color masks directly inside ComfyUI — with drag-and-drop shape manipulation, rotation, layers, and multiple shape types.

Features:

  • Interactive canvas editor with click-drag shape creation
  • 9 shape types: rectangle, ellipse, triangle, diamond, pentagon, hexagon, star, arrow, cross
  • Move, resize, and rotate shapes with intuitive handles
  • Layer system with z-index ordering
  • Per-shape color, opacity, rotation controls
  • Undo/Redo (Ctrl+Z / Ctrl+Y)
  • Keyboard shortcuts (V = Select, R = Rect, E = Ellipse, Del = Delete)
  • Shift + rotate for 15° snapping
  • Resolution-independent (coordinates stored as percentages)
  • Live preview on the node after saving

RGB Mask Splitter 🔀

image

Companion node that splits an RGB mask image into separate masks by color matching with configurable tolerance. Useful for applying different conditioning/prompts to each color region.

Region Select ✂️

Pick one or more movable rectangular regions on an image and send each one out as a crop — ideal for a "crop a region → regenerate it → paste it back" (inpaint/variation) workflow. Each region carries its own prompt, and everything needed to reassemble the image travels in a single region output.

Features:

  • Interactive preview inside the node: drag each region box to position it
  • Flexible image source: connect an image_override, or load a file in the node
  • Up to 8 regions, added/removed with the + / − buttons (num_regions)
  • Shared region size (width / height); each box is positioned independently
  • One prompt box that edits the selected region (click a box to select it)
  • Outputs: crop + crop_2… (one per region), the full image (for compare), x / y / width / height, per-region prompt / prompt_2…, and a region bundle (carries the original image plus every region's coordinates and prompt)

Region Stitch 🧩

Companion node that pastes externally-generated variants back into their original positions. Connect the region bundle from Region Select plus each generated variant, and it composites them onto the original image — no manual coordinates needed.

Features:

  • Positions variants automatically from the region bundle (matched by number: variant → region 1, variant_2 → region 2, …)
  • Variant inputs appear progressively as you connect them
  • Feathered blending (blur) to hide seams; variants are auto-resized to their region
  • Optional per-region mask to paste only part of a variant (white = keep variant) — pairs nicely with Impact Pack's Preview Bridge for painting masks on the variant

Conditioning Mask Combine (dynamic) 🎭

image

Combines multiple (positive, negative, mask) triplets into a single positive/negative conditioning pair — a drop-in replacement for chains of native Conditioning (Set Mask) + Conditioning (Combine) nodes.

Features:

  • Dynamic triplets: the node starts with one slot and automatically reveals the next one each time you connect an input (up to 10)
  • Per-triplet mask_strength and set_cond_area (default / mask bounds) — no shared settings
  • Incomplete triplets are skipped silently, so unused slots never block the workflow
  • Pairs naturally with RGB Mask Splitter for regional prompting

Installation

Manual

cd ComfyUI/custom_nodes/
git clone https://github.com/Phykrex/ComfyUI-Momo-Nodes.git

Restart ComfyUI. No additional dependencies required (uses Pillow, torch, numpy — already included with ComfyUI).

ComfyUI Manager

Search for Momo Nodes in the ComfyUI Manager and install.


Usage

Find all nodes under the MomoNodes/ category in the right-click node menu.

RGB Mask Editor workflow

RGB Mask Editor ✏️ → RGB Mask Splitter 🔀 → Conditioning Mask Combine (dynamic) 🎭 → KSampler
  1. Add RGB Mask Editor node, set width/height/background color
  2. Click 🎨 Open RGB Mask Editor to launch the visual editor
  3. Draw shapes with different colors for different regions
  4. Apply & Close to save
  5. Connect to RGB Mask Splitter to extract individual masks per color
  6. Feed each mask together with its own positive/negative conditioning into Conditioning Mask Combine (dynamic) — new triplets appear as you connect
  7. Pipe the combined positive/negative into your KSampler

Region variation workflow

Region Select ✂️ → (your sampler / edit model) → Region Stitch 🧩 → Save Image
                 └──────────────── region ──────────────┘
  1. Add Region Select, load or connect an image, set width / height and num_regions
  2. Drag each region box; click one to edit its prompt
  3. Send each crop (+ prompt) through your own sampler to get a variant
  4. Feed the region bundle and each variant into Region Stitch to reassemble the image

License

MIT

S
Description
No description provided
Readme MIT
78 KiB
Languages
JavaScript 69.8%
Python 30.2%