ComfyUI  >  Nodes  >  pre_cfg_comfy_nodes_for_ComfyUI >  Gradient RGB image

ComfyUI Node: Gradient RGB image

Class Name

Gradient RGB image

Category
image
Author
Extraltodeus (Account age: 3267 days)
Extension
pre_cfg_comfy_nodes_for_ComfyUI
Latest Updated
9/23/2024
Github Stars
0.0K

How to Install pre_cfg_comfy_nodes_for_ComfyUI

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

Gradient RGB image Description

Generate smooth color transitions in images with adjustable dimensions, direction, intensity, and patterns for artistic effects.

Gradient RGB image:

The Gradient RGB image node is designed to generate a smooth transition of colors across an image, creating a gradient effect. This node allows you to specify the dimensions of the image and the direction of the gradient, whether horizontal or circular. It also provides the flexibility to adjust the gradient's intensity and apply various patterns to achieve different visual effects. This node is particularly useful for creating backgrounds, overlays, or any artistic elements that require a gradual blend of colors. By manipulating the gradient parameters, you can achieve a wide range of aesthetic outcomes, enhancing the visual appeal of your AI-generated art.

Gradient RGB image Input Parameters:

width

The width parameter specifies the width of the generated gradient image in pixels. It determines the horizontal dimension of the image. The value should be a positive integer representing the number of pixels.

height

The height parameter specifies the height of the generated gradient image in pixels. It determines the vertical dimension of the image. The value should be a positive integer representing the number of pixels.

batch_size

The batch_size parameter defines the number of gradient images to generate in a single batch. This is useful for generating multiple images with the same gradient settings. The default value is 1, and it should be a positive integer.

r1, g1, b1

These parameters specify the starting color of the gradient in RGB format. Each parameter should be an integer between 0 and 255, representing the red, green, and blue components of the starting color, respectively.

r2, g2, b2

These parameters specify the ending color of the gradient in RGB format. Each parameter should be an integer between 0 and 255, representing the red, green, and blue components of the ending color, respectively.

axis

The axis parameter determines the direction of the gradient. It can be set to "horizontal" for a left-to-right gradient or "circular" for a radial gradient. This parameter affects how the colors transition across the image.

pattern_value

The pattern_value parameter allows you to apply different patterns to the gradient. It modifies the gradient's appearance by introducing variations such as linear or sine patterns. The value should be a float that influences the pattern's intensity.

power_to

The power_to parameter adjusts the intensity of the gradient by raising it to the specified power. This can create more pronounced or subtle transitions. The value should be a positive float, with higher values resulting in steeper gradients.

reverse_power

The reverse_power parameter is a boolean that, when set to True, reverses the effect of the power_to parameter. This can be used to invert the gradient's intensity adjustments.

mask

The mask parameter allows you to apply a mask to the gradient, controlling which parts of the image the gradient affects. The mask should be a tensor with the same dimensions as the gradient image. If provided, the gradient will be multiplied by the mask.

Gradient RGB image Output Parameters:

rgb_image

The rgb_image output is a tensor representing the generated gradient image in RGB format. Each pixel in the image contains the blended colors based on the specified gradient parameters. This output can be used directly in your AI art projects to create visually appealing backgrounds or overlays.

mask_gradient

The mask_gradient output is a tensor representing the gradient mask applied to the image. This mask shows the intensity of the gradient across the image and can be used for further processing or as a reference for other artistic effects.

Gradient RGB image Usage Tips:

  • Experiment with different axis settings to create unique gradient effects, such as horizontal or circular gradients.
  • Adjust the power_to parameter to fine-tune the intensity of the gradient, creating either subtle or dramatic transitions.
  • Use the mask parameter to apply the gradient selectively to specific areas of the image, enhancing the overall composition.
  • Combine different pattern_value settings to introduce interesting variations and textures to the gradient.

Gradient RGB image Common Errors and Solutions:

"Invalid dimensions for width or height"

  • Explanation: The width or height parameter is set to a non-positive value.
  • Solution: Ensure that both width and height are positive integers representing the number of pixels.

"Invalid color values for r1, g1, b1, r2, g2, b2"

  • Explanation: The color parameters are set to values outside the range of 0 to 255. - Solution: Ensure that all color parameters (r1, g1, b1, r2, g2, b2) are integers between 0 and 255.

"Invalid axis value"

  • Explanation: The axis parameter is set to a value other than "horizontal" or "circular".
  • Solution: Set the axis parameter to either "horizontal" or "circular" to specify the gradient direction.

"Mask dimensions do not match gradient dimensions"

  • Explanation: The provided mask does not have the same dimensions as the gradient image.
  • Solution: Ensure that the mask tensor has the same width and height as the gradient image before applying it.

Gradient RGB image Related Nodes

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