LayerStyle

2167
By chflame
Updated 15 days ago
View on GitHub →See Common Issues →

A set of nodes for ComfyUI that can composite layer and mask to achieve Photoshop like functionality.

Available Nodes

LayerUtility: ImageBlend

LayerUtility: ImageBlend Node Documentation

Overview

The LayerUtility: ImageBlend node is a functional component of the ComfyUI toolkit designed to facilitate advanced image compositing and blending operations. It allows users to combine a primary background image with an overlay or "layer" image using customizable blending modes, transparency settings, and optional masking. This node is particularly useful for creating complex visual compositions and enhancing digital artwork by layering multiple images with precision.

Input Parameters

The LayerUtility: ImageBlend node requires several input parameters to function effectively:

Required Inputs

  1. Background Image: The base image upon which the layer image will be blended. This image serves as the canvas to which additional visual elements are added.

  2. Layer Image: The image that will be overlaid onto the background. This image can contain elements such as textures, patterns, or specific visual features that you want to integrate into the background.

  3. Invert Mask: A boolean value (True or False) that determines whether the mask applied to the layer image should be inverted. By default, this is set to True, meaning the mask will be inverted.

  4. Blend Mode: A mode that dictates how the layer image is blended with the background. The node supports various blending modes that alter the visual interaction between the two images, similar to blending modes found in graphic design software.

  5. Opacity: An integer value representing the transparency of the layer image when blended with the background. The opacity can range from 0 (completely transparent) to 100 (completely opaque), allowing for fine-tuned adjustments. By default, this is set to 100.

Optional Inputs

  1. Layer Mask: An optional mask that determines which parts of the layer image are visible. If not provided, the default mask will ensure that the entire layer image is considered in the blending process.

Output

The output of the LayerUtility: ImageBlend node is:

  • Image: The resulting composite image, which is the product of blending the layer image with the background image according to the specified parameters. This image is suitable for further processing within ComfyUI workflows or for exporting and using as a final composition.

Usage in ComfyUI Workflows

The LayerUtility: ImageBlend node is used in ComfyUI workflows to perform complex image compositing tasks. It can be employed in scenarios such as:

  • Enhancing digital artwork by adding texture layers or visual effects.
  • Creating photo collages or montage effects.
  • Applying seamless overlays to images for artistic or branding purposes.
  • Designing graphics with specific blending techniques that emulate professional photo editing software.

Special Features and Considerations

  • The invert mask feature is particularly useful for photographers and digital artists who want to emphasize specific aspects of the layer image while suppressing others.
  • The node supports multiple batch processing, allowing for efficient handling of large numbers of images simultaneously.
  • The blend mode allows for a variety of creative effects, making it versatile for artistic experiments.
  • Users should ensure that the sizes of the background, layer, and mask images align to avoid unintended results.
  • Default settings offer a balance between usability and control, but experimentation with different parameter settings can yield unique and customizable results.