Nodes/MachinePainting Nodes/πŸ‘Ύ Color Match Blend
ComfyUI Node

πŸ‘Ύ Color Match Blend

Steal a look from any image, without the AI roulette

By machinepaintingΒ·Created 10 months agoΒ·Updated 4 months agoΒ· 9
πŸ‘Ύ Color Match Blend
  • target_image
  • reference_image
  • IMAGE
β—„strength0.75β–Ί
β—„enable_match_blendtrueβ–Ί
β—„saturation0β–Ί
β—„match_methodstatisticalβ–Ί
β—„blend_modenormalβ–Ί
β—„luminance_match0.00β–Ί
β—„color_match1.00β–Ί

Every so often you see a render with a color palette you love and think "I want that look on my image." Your first instinct is img2img or an IP-Adapter, which is a gamble - the model reshapes the whole image to get there. Color Match Blend is the deterministic path: it takes a target_image, a reference_image, and mathematically transfers the reference's color onto the target. No model, no denoise roulette, no "the face changed." If a LUT is a fixed recipe, this is a chef tasting your reference and cooking to match.

The three matching methods

  • statistical (default) - matches mean and standard deviation of color in LAB space. Fast and reliable; tends to homogenize (two similar references can give similar results, which is a known quirk of the method).
  • histogram - matches the full color histogram via cumulative-distribution matching. Preserves the reference's overall character better when the tonal shapes differ.
  • reinhard - the classic Reinhard color-transfer algorithm, the oldest and most "theoretical" of the three.

All three operate in LAB, so luminance and color are handled independently - which is why you also get luminance_match (0–1, default 0) and color_match (0–1, default 1) as separate strength controls. Want to keep your target's tones and only steal the palette? Drop luminance_match to 0, keep color_match at 1. That separation is the node's secret weapon.

Inputs that matter

  • target_image and reference_image (both required) - the photo/rendered image and the look source.
  • strength (default 0.75) - global blend of matched vs. original.
  • enable_match_blend (default on) - master switch for the whole matching stage; turn it off and the node is just a blend+grade utility.
  • saturation (βˆ’100 to 100) - final saturation trim after matching.
  • blend_mode - 10 modes (normal, overlay, multiply, screen, soft_light, hard_light, color, luminosity, darken, lighten). Leave normal unless you know what you're doing; color is the usual choice when you only want the matched hue.

Output is a single IMAGE. Chain it before a Save node or feed it into further grade nodes.

Install

Part of MachinePainting Nodes:

cd ComfyUI/custom_nodes
git clone https://github.com/machinepainting/ComfyUI-MachinePaintingNodes.git
pip install -r requirements.txt

or ComfyUI Manager β†’ "MachinePaintingNodes" β†’ install β†’ restart.

Troubleshooting

The recurring complaint with any statistical match is "everything comes out the same color." That's the method, not a bug: statistical matching normalizes to the reference's mean and variance, so two references with similar statistics converge. Fixes: use histogram for more character, dial strength down, or gate the match behind enable_match_blend and use color_match/luminance_match to control exactly what transfers. Also match against a neutral reference if you want subtle correction; matching against a heavily graded frame will paint your whole image with that grade, which is either what you wanted or a strong hint to back the strength off.

CategoryMachinePaintingNodes/Color

Inputs (9)

NameTypeDefaultDescription
target_imageIMAGEβ€”
reference_imageIMAGEβ€”
strengthFLOAT0.750–1β€”
enable_match_blendBOOLEANtrueβ€”
saturationFLOAT0-100–100β€”
match_methodoptCOMBOstatistical3 options: statistical, histogram, reinhard
blend_modeoptCOMBOnormal10 options: normal, overlay, multiply, screen, soft_light, hard_light, +4
luminance_matchoptFLOAT0.000–1β€”
color_matchoptFLOAT1.000–1β€”

Outputs (1)

NameTypeDescription
IMAGEIMAGEβ€”