Nodes/radiance/◎ Radiance Bit Depth Convert
ComfyUI Node

◎ Radiance Bit Depth Convert

Going from float to 8-bit without the banding

By fxtdstudios·Created 7 months ago·Updated 9 days ago· 242
◎ Radiance Bit Depth Convert
  • image
  • converted_image
  • bit_depth_info
output_depth
ditheringNone
dither_strength1.0
seed0

Here's a fact of life in ComfyUI: the fancy 32-bit float image you graded beautifully has to come back down to a normal integer format eventually, and the moment it does, the banding appears. RadianceBitDepthConvert is the node that manages that descent - converting between 32-bit float, 16-bit float, 16-bit int, 10-bit, and 8-bit, with a proper dithering stage to break up the quantization bands before they become visible.

It's a small node with a serious job. Quantization is where HDR work dies: smooth gradients in float become hard steps at 8-bit, and the classic visible symptom is banding in skies and gradients. Dithering is the fix - it spreads the quantization error as high-frequency noise that the eye reads as texture instead of steps. This node implements real algorithms, not a random nudge.

The inputs

  • image - expects float32 input (per the tooltip: "Input image in float32 format"), so run ImageToFloat32 upstream if you aren't already in float.
  • output_depth - 32-bit Float / 16-bit Float / 16-bit Int / 10-bit / 8-bit. The one that matters for delivery is usually 16-bit Int (for EXR/PNG workflows) or 8-bit (for anything that's going to a web page).
  • dithering - None / Floyd-Steinberg / Ordered / Blue Noise / Random. Floyd-Steinberg is the error-diffusion classic and the safe default when you're dropping to 8-bit. Blue Noise gives a high-frequency, less structured result that tends to look cleaner on gradients. Ordered is Bayer-pattern. Random is just noise. If you're keeping 16-bit+, you can usually skip dithering entirely.
  • dither_strength (0–2, default 1) - intensity of the dither. 1.0 standard; lower if the noise texture bothers you, higher if banding persists.
  • seed - reproducible Blue Noise / Random dithering, so two runs with the same seed give the same grain. Set it if you're comparing outputs.

Outputs: converted_image (quantized to the target depth) and bit_depth_info (a STRING describing what happened - wire to ShowText if you're auditing the pipeline).

Where it fits

The end of the chain, obviously - after tone mapping (for SDR) or directly on float data (if you're writing 16-bit EXR). The honest workflow advice: don't downgrade earlier than you have to. Keep your float image through the grade, and only convert at the very end for the specific deliverable. And remember that dithering is a cosmetic fix - it hides quantization, it doesn't restore precision. If the banding is bad, the real fix is upstream (a 16-bit source, a better gradient, or tone mapping that doesn't stretch the midtones so hard).

It also shines for a specific niche: converting to 10-bit for video deliverables (the pack's IO story is digital-cinema-flavored), where 10-bit with dithering looks noticeably cleaner than a straight 8-bit export.

Install

Part of Radiance - ComfyUI Manager → search Radiance, or:

cd ComfyUI/custom_nodes
git clone https://github.com/fxtdstudios/radiance.git
cd radiance
pip install -r requirements.txt

Restart. Under FXTD Studios/Radiance/Image.

CategoryFXTD Studios/Radiance/Image

Inputs (5)

NameTypeDefaultDescription
imageIMAGEInput image in float32 format.
output_depthCOMBOTarget bit depth.
ditheringoptCOMBONoneDithering algorithm. Floyd-Steinberg = error diffusion, Ordered = Bayer, Blue Noise = high-frequency, Random = simple noise.
dither_strengthoptFLOAT1.00–2Dithering intensity. 1.0 = standard.
seedoptINT00–18446744073709550000Random seed for reproducible Blue Noise and Random dithering.

Outputs (2)

NameTypeDescription
converted_imageIMAGEImage quantized to target bit depth.
bit_depth_infoSTRINGInformation about the conversion.