Nodes/ComfyUI-DonutNodes/Donut Image Adjust
ComfyUI Node

Donut Image Adjust

A ComfyUI node in donut/image with 21 inputs and 2 outputs.

By DonutsDelivery·Created about a year ago·Updated a day ago· 22
Donut Image Adjust
  • image
  • image
  • gamma
operationgamma
ag_methodgslf
ag_strength1.0
ag_target0.50
ag_percentile50
ag_directionboth
gm_gamma0
gm_dither0.0
wb_methodgray_world
wb_strength1.0
wb_clip_percent0.1
hs_black_point0.0
hs_white_point100.0
hs_modeluminance
lc_radius20
lc_amount0.20
lc_protect_tones0.0
lc_fast_blurtrue
cas_sharpness0.50
cas_contrast0.0
Categorydonut/image

Inputs (21)

NameTypeDefaultDescription
imageIMAGE
operationCOMBOgammaWhich image adjustment operation to apply.
ag_methodoptCOMBOgslfDetection method: simple_mean (fastest), iagcwd (deviation-based), gslf (histogram-based, most sophisticated), percentile (robust to outliers)
ag_strengthoptFLOAT1.00–2Correction strength (1.0 = full correction)
ag_targetoptFLOAT0.500.1–0.9Target value for simple_mean and percentile methods
ag_percentileoptFLOAT501–99Which percentile to target (percentile method only)
ag_directionoptCOMBObothboth: auto brighten/darken, brighten_only: only brighten dark images, darken_only: only darken bright images
gm_gammaoptFLOAT0-100–100Gamma adjustment (-100 to +100). Positive brightens shadows, negative darkens them.
gm_ditheroptFLOAT0.00–2Dither amount to reduce banding (0 = off, 0.5 = subtle, 1.0 = 1 LSB worth of noise)
wb_methodoptCOMBOgray_worldgray_world: shift means to gray. white_patch: scale by brightest. combined: both. auto_levels: per-channel stretch (Auto Tone). photoshop: per-channel + midtone snap (Auto Color)
wb_strengthoptFLOAT1.00–2Correction strength (1.0 = full correction)
wb_clip_percentoptFLOAT0.10–10Percent of pixels to clip from brightest/darkest (Photoshop default: 0.1%)
hs_black_pointoptFLOAT0.00–49Percentile for black point (0 = absolute min, 1+ = robust)
hs_white_pointoptFLOAT100.051–100Percentile for white point (100 = absolute max, 99- = robust)
hs_modeoptCOMBOluminanceglobal: bounds from luminance, same stretch to RGB (preserves ratios). per_channel: stretch RGB independently (may shift colors). luminance: LAB L-only (preserves hue/saturation, matches LayerStyle)
lc_radiusoptFLOAT201–200Large radius for local contrast enhancement
lc_amountoptFLOAT0.200–1Keep low to avoid halos (0.1-0.3 typical)
lc_protect_tonesoptFLOAT0.00–1Protect shadows/highlights from clipping
lc_fast_bluroptBOOLEANtrueUse separable blur (faster, identical quality)
cas_sharpnessoptFLOAT0.500–1Sharpening strength
cas_contrastoptFLOAT0.0-1–1Contrast adjustment (0 = neutral)

Outputs (2)

NameTypeDescription
imageIMAGE
gammaFLOAT