ComfyUI  >  Nodes  >  ComfyUI Layer Style >  LayerMask: MaskStroke

ComfyUI Node: LayerMask: MaskStroke

Class Name

LayerMask: MaskStroke

Category
😺dzNodes/LayerMask
Author
chflame163 (Account age: 445 days)
Extension
ComfyUI Layer Style
Latest Updated
6/24/2024
Github Stars
0.6K

How to Install ComfyUI Layer Style

Install this extension via the ComfyUI Manager by searching for  ComfyUI Layer Style
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI Layer Style in the search bar
After installation, click the  Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

LayerMask: MaskStroke Description

Enhance image processing workflow with precise mask stroke manipulation for detailed and customizable artistic effects.

LayerMask: MaskStroke:

The LayerMask: MaskStroke node is designed to enhance your image processing workflow by allowing you to create and manipulate mask strokes with precision. This node is particularly useful for AI artists who need to apply detailed and customizable strokes to their masks, enabling more refined control over the visual elements of their artwork. By leveraging this node, you can invert masks, adjust stroke growth, set stroke width, and apply blur effects, all of which contribute to achieving the desired artistic effects. The primary goal of this node is to provide a flexible and powerful tool for mask manipulation, making it easier to create complex and visually appealing compositions.

LayerMask: MaskStroke Input Parameters:

mask

The mask parameter is the primary input for the node, representing the mask to which the stroke will be applied. This parameter is essential as it defines the area where the stroke effects will be executed.

invert_mask

The invert_mask parameter is a boolean option that allows you to invert the mask before applying the stroke. When set to True, the mask will be inverted, which can be useful for creating negative space effects. The default value is True.

stroke_grow

The stroke_grow parameter is an integer that determines the amount by which the stroke will grow or shrink. Positive values will expand the stroke, while negative values will contract it. This parameter allows for fine-tuning the stroke's size to match your artistic vision. The default value is 0, with a minimum of -999 and a maximum of 999.

stroke_width

The stroke_width parameter is an integer that sets the width of the stroke. This parameter controls how thick or thin the stroke will be, providing flexibility in the visual impact of the stroke. The default value is 20, with a minimum of 0 and a maximum of 999.

blur

The blur parameter is an integer that applies a blur effect to the stroke. This parameter helps to soften the edges of the stroke, creating a smoother transition and a more polished look. The default value is 6, with a minimum of 0 and a maximum of 100.

LayerMask: MaskStroke Output Parameters:

mask

The mask output parameter is the resulting mask after the stroke has been applied. This output is crucial as it represents the final mask with the stroke effects incorporated, ready to be used in further image processing or artistic compositions.

LayerMask: MaskStroke Usage Tips:

  • Experiment with the stroke_grow and stroke_width parameters to achieve the desired stroke size and effect. Start with small adjustments and gradually increase or decrease the values to see the impact on your mask.
  • Use the blur parameter to soften the edges of your stroke, especially if you are aiming for a more natural and less harsh transition between the stroke and the mask.
  • Inverting the mask using the invert_mask parameter can create interesting negative space effects, which can add depth and complexity to your artwork.

LayerMask: MaskStroke Common Errors and Solutions:

Mask dimension mismatch

  • Explanation: This error occurs when the dimensions of the input mask do not match the expected dimensions.
  • Solution: Ensure that the input mask has the correct dimensions before applying the stroke. You may need to resize or adjust the mask to match the expected size.

Invalid parameter values

  • Explanation: This error occurs when one or more input parameters have values outside the acceptable range.
  • Solution: Double-check the values of stroke_grow, stroke_width, and blur to ensure they fall within the specified ranges. Adjust the values accordingly to avoid this error.

Mask inversion issues

  • Explanation: This error occurs when the mask inversion does not produce the expected results.
  • Solution: Verify that the invert_mask parameter is set correctly. If the inversion does not look right, try toggling the invert_mask parameter and re-evaluate the results.

LayerMask: MaskStroke Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI Layer Style
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.