Nodes/ComfyUI DCI/DCI Image
ComfyUI Node

DCI Image

Turn any ComfyUI image into a real Linux icon

By zccrs·Created about a year ago·Updated 11 months ago· 2
DCI Image
  • Image
  • DCI Image Data
  • Path
  • Binary Data
Icon Size256
Icon StateNormal
Scale1.0
Tone TypeUniversal
Image Formatwebp
Image Quality90
WebP Losslessfalse
WebP Alpha Quality100
PNG Compress Level6
Background ColorTransparent
Custom Background Red255
Custom Background Green255
Custom Background Blue255
Layer Priority1
Layer Padding0
Palette TypeNone
Hue Adjustment0
Saturation Adjustment0
Brightness Adjustment0
Red Adjustment0
Green Adjustment0
Blue Adjustment0
Alpha Adjustment0

This is the node the whole pack is built around, and the most confusing one to meet cold, so let's clear the air first: DCI doesn't stand for anything diffusion-related. It's DSG Combined Icons, a binary container format from the Linux desktop world (think Deepin, the DTK icon toolkit) that bundles every variant of an app icon - normal, hover, pressed, disabled, light and dark tone, all the scale factors - into a single .dci archive. This pack, from zccrs (who maintains the DCI spec itself), is basically a pipeline for generating that with AI: render icon art in ComfyUI, hand it to this node, and out comes a properly named icon layer ready to be stitched into a real icon file.

What it does: takes any IMAGE tensor, resizes it to your icon size, encodes it as WebP, PNG, or JPEG, and returns a DCI_IMAGE_DATA object - a little packet that carries the encoded bytes, the DCI path it belongs at, and a pile of metadata describing the layer.

The inputs that actually matter on day one:

  • Image - your generated art. Feed it RGBA if you want transparency.
  • Icon Size (16–1024, default 256) - the base size in pixels.
  • Icon State - Normal, Disabled, Hover, or Pressed. Generate one state per node, wire four of these into a DCI File node later.
  • Scale (0.1–10) - multiplies the base size. DCI supports fractional scales like 1.25x and 1.5x, and it's genuinely useful for HiDPI themes.
  • Tone Type - Universal, Light, or Dark. Universal is the default and the smart one: the pack stores the image in the light directory and creates a relative symlink in the dark directory, so one asset covers both themes.

The Tone Type and Icon State choices matter because they become part of the path the file lands at: <size>/<state>.<tone>/<scale>/<filename>. And the filename isn't random - DCI encodes layer properties into it like 1.0p.-1.0_0_0_0_0_0_0.webp (priority, padding, palette, then hue/saturation/brightness/red/green/blue/alpha adjustments). The optional inputs control exactly that: Layer Priority, Layer Padding, Palette Type, and the seven color adjustment sliders all get baked into the name per the spec. Most people leave them alone; they're there for the icon-theme pedants who need pixel-exact layer metadata.

Also optional but worth knowing: Background Color (Transparent, White, Black, Custom, Checkerboard - checkerboard is a compositing trick so you can preview transparency without an alpha channel), Image Format (webp is the right default; jpg silently flattens transparency), Image Quality, WebP Lossless, WebP Alpha Quality, and PNG Compress Level.

Three outputs come out: DCI Image Data (the packet - wire it into the DCI File node), Path (a string like 256/normal.light/1/1.0p.-1...webp, handy for display or naming), and Binary Data (the raw encoded image bytes, if you want to save or inspect the image alone).

Installing

It's a light pack - dependencies are just Pillow and numpy, no models to download, nothing to fetch from HuggingFace. Install via ComfyUI Manager by searching "DCI Image Export Extension" or "comfyui-dci", or the old-fashioned way:

cd ComfyUI/custom_nodes
git clone https://github.com/zccrs/comfyui-dci
cd comfyui-dci
pip install -r requirements.txt   # or ./install.sh on Linux/Mac

Restart ComfyUI and the nodes appear under the DCI category.

Where people get burned

  • JPEG loses your alpha. Pick it and transparent icons come out on a white square. Use WebP or PNG.
  • The node only resizes, it doesn't design. Your art should already be roughly square with the subject centered; Icon Size just scales it down (LANCZOS).
  • It's a niche pack. This thing has basically zero community footprint - don't expect blog posts or tutorial threads. If something's odd, read the node's own (heavily instrumented) error output; the pack leans on detailed console logging.
  • Expect the layer filename to look weird. 1.0p.-1.0_0_0_0_0_0_0.webp is correct, not a bug. It's the spec.

If you're not building a Deepin/DSG-style icon theme, this node is probably not for you. If you are - or you just like the idea of your SD output ending up as a system icon - this is the cleanest way to get there.

CategoryDCI/Export

Inputs (24)

NameTypeDefaultDescription
ImageIMAGE
Icon SizeINT25616–1024
Icon StateCOMBONormal4 options: Normal, Disabled, Hover, Pressed
ScaleFLOAT1.00.1–10
Tone TypeCOMBOUniversal3 options: Universal, Light, Dark
Image FormatoptCOMBOwebp3 options: webp, png, jpg
Image QualityoptINT901–100
WebP LosslessoptBOOLEANfalse
WebP Alpha QualityoptINT1000–100
PNG Compress LeveloptINT60–9
Background ColoroptCOMBOTransparent5 options: Transparent, White, Black, Custom, Checkerboard
Custom Background RedoptINT2550–255
Custom Background GreenoptINT2550–255
Custom Background BlueoptINT2550–255
Layer PriorityoptINT11–100
Layer PaddingoptINT00–100
Palette TypeoptCOMBONone5 options: None, Foreground, Background, Highlight Foreground, Highlight
Hue AdjustmentoptINT0-100–100
Saturation AdjustmentoptINT0-100–100
Brightness AdjustmentoptINT0-100–100
Red AdjustmentoptINT0-100–100
Green AdjustmentoptINT0-100–100
Blue AdjustmentoptINT0-100–100
Alpha AdjustmentoptINT0-100–100

Outputs (3)

NameTypeDescription
DCI Image DataDCI_IMAGE_DATA
PathSTRING
Binary DataBINARY_DATA