π Compositor Color Picker
One color, four formats, and a button that steals pixels off your screen
- color_string
- color_16bit
- color_24bit
- color_preview
If you've ever sat in ComfyUI trying to set a solid background color and realized the Empty Image node wants a single 24-bit integer while everything else in your workflow wants a hex string, this node exists to end that conversation. You give it one RGB color and it hands you back the same color in every format the ecosystem actually uses: a hex string, a 16-bit value, a 24-bit value, and a preview image.
It's a utility node - no secrets, no inference - but it's the right kind of utility: it removes a whole class of "how do I convert this color" fussing, and the frontend adds a genuine quality-of-life trick.
Inputs
red,green,blue- each 0β255 (default 0). That's the whole color.format-RGB565orRGB555, which affects only the 16-bit output's bit packing. RGB565 spends 5 bits on red, 6 on green, 5 on blue; RGB555 splits 5/5/5. Unless you're driving hardware that cares (old-school embedded displays, some shader packs), leave it on RGB565.
Outputs
color_string- hex, like#FF8000.color_16bit- packed 16-bit value (the RGB565/RGB555 format above).color_24bit- the(r << 16) | (g << 8) | bvalue, 0β16777215. This is the one ComfyUI's Empty Image node accepts for a solid background.color_preview- a 128Γ128 IMAGE of the color, so you can eyeball it without squinting at hex.
The frontend also adds a color swatch and an eyedropper (π) that uses the browser's EyeDropper API to grab a color from anywhere on your screen - including that reference image open in another window. Handy for matching a palette you're already looking at.
Installing
Part of the same pack, no models, no extra deps:
cd ComfyUI/custom_nodes
git clone https://github.com/erosDiffusion/ComfyUI-enricos-nodes.git
or ComfyUI Manager β search "Compositor" β erosDiffusion. Restart.
Gotchas
Two small things. The eyedropper depends on the browser's EyeDropper API - it works in Chromium-based browsers and is spotty or absent elsewhere; if the button does nothing, check your browser before your node. And the node is pure data conversion, so there's no "wrong" output - if a downstream node rejects the value, it's almost always because it wants the 24-bit form and you fed it the hex string, or vice versa. When in doubt, the color_24bit output is the one ComfyUI's own nodes expect.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| red | INT | 00β255 | β |
| green | INT | 00β255 | β |
| blue | INT | 00β255 | β |
| format | COMBO | RGB565 | 2 options: RGB565, RGB555 |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| color_string | STRING | β |
| color_16bit | INT | β |
| color_24bit | INT | β |
| color_preview | IMAGE | β |