Hex To Other (Shinsplat)
The two-output hex converter for when a number arrives as a string
- _int
- _flt
A one-line job made into a node: take a hex string like "ff" and hand back the number. The README calls it "convert a string representation of a hex value to an integer/float output," and that's the whole thing - a text input and two outputs, _int and _flt, for when whatever you're feeding you needs the value as one type or the other. It exists because in ComfyUI a number can arrive as a string from a text node, a variable dictionary, or a file reader, and the stock graph has no convenient conversion for hex.
How it works
You type (or pipe in) a hex string - 0xff style prefixes work, and so does bare ff - and the node interprets it as an integer, then exposes that integer on _int and the same value as a float on _flt. Two outputs, same number, two types, so you can wire the one the destination expects without a converter chain in between. There's no validation drama: bad input just produces the standard parse failure, and the default text is "0" so an empty node still outputs something sane.
Realistically this is a corner utility. It shows up when you're parsing hex seeds, hex color components, or hex-encoded config values pulled out of a file or an API payload - the "I need this as a number but it arrived as text" moment.
The inputs and outputs
text- the hex string, default"0".- Outputs:
_int(INT) and_flt(FLOAT), both the decoded value.
How to install it
Included in ComfyUI-Shinsplat:
cd ComfyUI/custom_nodes
git clone https://github.com/Shinsplat/ComfyUI-Shinsplat
or ComfyUI Manager → "ComfyUI-Shinsplat" → restart. No extra deps.
Common issues
- "It failed to parse my string" - check for stray whitespace or a
0xyou dropped on one input but not the other; the node is a straight hex-to-int conversion, not a type-flexible parser. - "I need a negative" - hex doesn't carry a sign here; negate downstream with a math node if you need it.
- "I expected a color node" - this one only converts the number; RGB/hex color math is out of scope for a two-port converter.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| text | STRING | 0 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| _int | INT | — |
| _flt | FLOAT | — |