Voxel Video API Input Node
Feed base64 images and click-coordinates into your graph — the API part is just the name
- images
- positive_coordinates
The name is a lie, but a useful one. Voxel Video API Input Node doesn't call any API and needs no key - it's the intake valve for one. The idea is that an external server (the author's companion voxel-video service) wants to push images plus click-coordinates into a running ComfyUI graph, and this node is the dock where that payload lands. If you're not running that companion service, you probably don't need this node. But if you're building your own pipeline that receives image data over HTTP, this is a working example of how to do it inside a node.
How it works
Both inputs are strings, which is the giveaway that this node is speaking a network protocol, not ComfyUI types:
- images (
STRING) - a JSON array as text, where each element is either a base64 data URI (data:image/png;base64,...) or anhttp(s)URL. - positive_coordinates (
STRING) - a JSON array of{x, y}objects, presumably marking where in the image the voxels should be placed.
On execute, the node loads every image (URLs via requests, base64 via base64 + Pillow), applies EXIF transposition, converts to an RGB float tensor, resizes any stragglers to match the first image using ComfyUI's own common_upscale (lanczos), and concatenates them into one batch. Then it rescales the coordinates: if the source image is wider than 512px, it computes a new height that keeps proportions and multiplies every x and y to fit a 512-wide canvas.
What comes out
- images (
IMAGE) - the loaded batch of tensors, ready to plug into a VAE encode, a segmenter, or whatever your graph does next. - positive_coordinates (
STRING) - the rescaled coordinate JSON, passed straight through to whichever node consumes it.
Where it bites
- Empty array = a
Nonetensor. Ifimagesparses to an empty list, the node returnsNonefor the image output and whatever's downstream will explode. There's no friendly fallback. - The scaling rule is conditional. Coordinates only get rescaled when the source width is greater than 512. Feed it a 1024px image and coords are scaled down to a 512-wide canvas; feed it a 400px image and the coordinates pass through untouched. If your caller isn't aware of that rule, the click positions will silently drift.
- It uses the last image's dimensions for the coordinate math. With mixed-size images, the "source" size isn't a clean single value - expect the scaling to be approximate rather than precise.
Installing it
Same pack install as the rest of ComfyUI-Voxels:
# ComfyUI Manager: search "ComfyUI-Voxels", or:
cd ComfyUI/custom_nodes
git clone https://github.com/DanielHabib/ComfyUI-Voxels
# restart ComfyUI
Dependencies here are Pillow, requests, and torch - all of which ComfyUI already ships, and the pack has no requirements.txt anyway. The whole repo is a single commit from September 2024, so this node is best read as a reference for how to receive base64/URL image payloads in a custom node than as a production API endpoint. If you just want to make voxel videos from meshes, you can skip it entirely.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| images | STRING | — | |
| positive_coordinates | STRING | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| images | IMAGE | — |
| positive_coordinates | STRING | — |