ComfyUI > Nodes > Sketch2Manga > BlendScreentone

ComfyUI Node: BlendScreentone

Class Name

BlendScreentone

Category
image/postprocessing
Author
dmMaze (Account age: 1904days)
Extension
Sketch2Manga
Latest Updated
2024-06-30
Github Stars
0.03K

How to Install Sketch2Manga

Install this extension via the ComfyUI Manager by searching for Sketch2Manga
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter Sketch2Manga 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

BlendScreentone Description

BlendScreentone: Node blending colorized images with screentone patterns for manga/comic art, enhancing visual appeal and depth.

BlendScreentone:

BlendScreentone is a powerful node designed to blend colorized images with screentone patterns, commonly used in manga and comic art. This node leverages advanced image processing techniques to seamlessly integrate screentone textures into colorized artwork, enhancing the visual appeal and depth of the final image. By adjusting various parameters, you can control the blending process to achieve the desired artistic effect, making it an essential tool for AI artists looking to create high-quality manga-style illustrations. The node's primary goal is to provide a flexible and efficient method for combining color and screentone, ensuring that the resulting images maintain a consistent and professional look.

BlendScreentone Input Parameters:

colorized

This parameter represents the colorized image that you want to blend with the screentone. It should be provided as a NumPy array in RGB format. The quality and resolution of this image will directly impact the final output, so it's important to use a high-quality source image.

screened

This parameter is the screentone pattern that will be blended with the colorized image. It should also be provided as a NumPy array. The screentone can be in grayscale or RGB format, but if it's in RGB, it will be converted to grayscale during processing. The screentone pattern adds texture and depth to the colorized image.

cluster_n

This parameter controls the number of clusters used for dividing the image into regions. The default value is 10. Increasing this value can result in more detailed and varied blending, while decreasing it can simplify the blending process. The range of acceptable values typically starts from 1 and can go up to the number of distinct regions you want to identify in the image.

tone_std_tol

This parameter sets the tolerance for the standard deviation of tones within each region. The default value is 5. It helps in controlling the variation of tones in the blended image. A higher value allows for more variation, while a lower value restricts it, leading to a more uniform appearance.

vis_layers

This boolean parameter, when set to True, enables the visualization of the different layers created during the clustering process. The default value is False. This can be useful for debugging or for understanding how the image is being divided and processed.

seed

This parameter allows you to set a seed for the random number generator, ensuring reproducibility of the blending process. If not provided, the blending will be non-deterministic. This is particularly useful when you need consistent results across multiple runs.

scale_by_region

This boolean parameter determines whether the blending should be scaled by region. The default value is True. When set to False, the blending will be applied uniformly across the entire image, which can be useful for simpler blending tasks.

BlendScreentone Output Parameters:

screentone_colorized

This output is the final blended image, combining the colorized input with the screentone pattern. It is provided as a NumPy array in RGB format. This image is the main result of the blending process and can be used directly in your artwork.

layers

This output provides the different layers created during the clustering process. Each layer represents a distinct region of the image, which can be useful for further processing or analysis. It is provided as a NumPy array.

layers_vis

This output is a visualization of the different layers, showing how the image was divided during the clustering process. It is also provided as a NumPy array and can be useful for understanding the blending process and for debugging purposes.

BlendScreentone Usage Tips:

  • Experiment with the cluster_n parameter to find the optimal number of regions for your specific image. More clusters can provide finer detail but may increase processing time.
  • Use the tone_std_tol parameter to control the variation in tones. Adjusting this can help achieve the desired level of texture and depth in the final image.
  • Enable vis_layers to visualize the clustering process and understand how the image is being divided. This can be particularly useful for fine-tuning the blending parameters.
  • Set the seed parameter to ensure consistent results across multiple runs, especially when working on a series of images that need to maintain a uniform style.

BlendScreentone Common Errors and Solutions:

"Input images must be NumPy arrays"

  • Explanation: This error occurs when the input images are not provided as NumPy arrays.
  • Solution: Ensure that both the colorized and screened inputs are correctly formatted as NumPy arrays before passing them to the node.

"Mismatch in image dimensions"

  • Explanation: This error occurs when the dimensions of the colorized and screened images do not match.
  • Solution: Resize the images to have the same dimensions using an image processing library like OpenCV before blending.

"Invalid value for cluster_n"

  • Explanation: This error occurs when the cluster_n parameter is set to a value outside the acceptable range.
  • Solution: Ensure that cluster_n is set to a positive integer that makes sense for the level of detail you want to achieve.

"Tone standard deviation tolerance too high"

  • Explanation: This error occurs when the tone_std_tol parameter is set to an excessively high value, leading to unrealistic blending.
  • Solution: Adjust the tone_std_tol parameter to a more reasonable value, typically between 1 and 10, to achieve a balanced blending effect.

BlendScreentone Related Nodes

Go back to the extension to check out more related nodes.
Sketch2Manga
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.