Eric Qwen Layer Composite
Flatten your Qwen layers back into one image — with real blend modes
- layers
- alpha_masks
- composite
- composite_alpha
Decompose gives you layers; sometimes you want the picture back. EricQwenLayerComposite stacks a batch of RGBA layers bottom-to-top with proper alpha blending and returns a single flattened image - plus its combined alpha, so you can keep treating the result as one more layer downstream.
How it works
The stack is composited in batch order, first image at the bottom. Each layer's alpha is respected during the blend, and you get real Photoshop-style blend modes on top of that: normal, multiply, screen, overlay, darken, lighten, color_dodge, color_burn, hard_light, soft_light, difference, and exclusion. A global_opacity (0–1) applies to every layer as a group, and background_color (transparent, white, black, or gray) fills whatever the alpha doesn't cover.
The two outputs are composite (IMAGE) and composite_alpha (MASK). That second one matters more than it looks: it's the union alpha of the whole stack, so you can feed the composite back into another layer-based workflow, or cut it out of a new background, without losing the transparency information.
The two ways you'll use it
Reconstruct. Run a decompose → composite with normal blending and you should get something very close to your original image. It won't be pixel-identical - the model re-generates each layer, so edges shift a little - but it's the fastest sanity check that your decomposition didn't lose anything. If the composite looks wrong, you caught the problem before it reached the save node.
Preview the stack. 10 layers is a lot to eyeball in a grid. Composite them and inspect one image. When you spot that one element you want gone, go back and Selector it out, then re-composite.
One trap worth naming: because order is bottom-to-top, a layer you expect to be on top needs to be later in the batch. Pair this node with the pack's Reorder node if your stack isn't in the order you want - compositing can't read your mind.
Installation is the pack standard - ComfyUI Manager (search "Eric Qwen") or git clone https://github.com/EricRollei/Qwen_Layers_Diffuser_Pipeline_Comfyui into custom_nodes, then restart. Pure tensor math, no model involved, so it's instant even right after a heavy decompose.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| layers | IMAGE | — | |
| blend_mode | COMBO | normal | Blend mode for compositing layers |
| alpha_masksopt | MASK | — | |
| background_coloropt | COMBO | transparent | Background for the composite |
| global_opacityopt | FLOAT | 1.000–1 | Global opacity applied to all layers |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| composite | IMAGE | — |
| composite_alpha | MASK | — |