Nodes/ComfyUI-Apt_Preset/color_lineGradient_visual
ComfyUI Node

color_lineGradient_visual

A linear gradient generator with a live preview

By cardenluo·Created 2 years ago·Updated 22 days ago· 309
color_lineGradient_visual
  • image
  • gradient_image
start_x0.00
start_y0.00
start_bright0.50
end_x1.00
end_y1.00
end_bright1.00
overlay_color#FFFFFF
start_alpha0.00
end_alpha0.00

Two anchor points, each with its own brightness and an optional color tint, interpolated linearly across the image - that's the same idea as this pack's color_brightGradient, but flagged as an output node so it renders the result inline on the canvas as you drag values, and shipping with a lower default start_bright (0.5 instead of 1.0), meaning out of the box this one leans toward darkening from the start point rather than staying neutral. It lives in Apt_Preset/image/visualize_edit, the pack's bucket for nodes built to be watched while you tune them.

Use it for the same jobs as any linear gradient tool: a soft directional light falloff, a graduated darkening across part of the frame, or a two-tone tint fading from one side to another.

How it works

start_x/start_y and end_x/end_y place two arbitrary points anywhere on the frame (not necessarily edge to edge), and brightness interpolates linearly between start_bright and end_bright. A color tint via overlay_color with start_alpha/end_alpha fades in on top of the brightness ramp - off by default since both alphas start at 0.

The inputs and outputs that matter

  • start_x / start_y / end_x / end_y (0-1, defaults 0/0 and 1/1) - the two gradient anchor points.
  • start_bright (0-5, default 0.5) and end_bright (0-5, default 1) - the default already leans darker at the start.
  • overlay_color (hex, default #FFFFFF) with start_alpha/end_alpha (0-1, default 0) - the tint layer, invisible until alpha is raised.
  • image in, gradient_image out - plus a live preview on the node itself since it's an output node.

How to install it

Through ComfyUI Manager: search "ComfyUI-Apt_Preset", install, restart. Manually:

cd ComfyUI/custom_nodes
git clone https://github.com/cardenluo/ComfyUI-Apt_Preset.git

then run install.bat (Windows) or install requirements manually on Linux/Mac, and restart. No model downloads for this node.

Common issues & troubleshooting

Image looks darker than expected right out of the box. start_bright defaults to 0.5, not 1 - that's already a real darkening at the start point, not neutral. Push it back toward 1 if you wanted a flat starting brightness.

No visible color tint. start_alpha/end_alpha both default to 0 - raise them to see overlay_color.

Gradient runs the wrong direction. start_x/start_y and end_x/end_y are just two independent points, not fixed to left-to-right - swap them.

Don't need the live preview mid-pipeline? color_brightGradient covers similar ground without the forced output-node behavior, for burying deeper in a longer graph.

IMPORT FAILED on the pack. ComfyUI-Apt_Preset is large and updates often; users have reported import failures after some updates. Reinstall via Manager before assuming it's this node.

CategoryApt_Preset/image/visualize_edit

Inputs (10)

NameTypeDefaultDescription
imageIMAGE
start_xFLOAT0.000–1
start_yFLOAT0.000–1
start_brightFLOAT0.500–5
end_xFLOAT1.000–1
end_yFLOAT1.000–1
end_brightFLOAT1.000–5
overlay_colorSTRING#FFFFFF
start_alphaFLOAT0.000–1
end_alphaFLOAT0.000–1

Outputs (1)

NameTypeDescription
gradient_imageIMAGE