ParticleBoy Studio
A full WebGL particle studio hiding inside one ComfyUI node
- frames
- video
ParticleBoy is not a node that adds particles to a diffusion model. It's a whole GPU particle simulator - a WebGL studio with sliders, an orbit camera, and GLB import - embedded as a widget inside a ComfyUI node. You play with the fountain in the node, hit Queue Prompt, and out pops an IMAGE batch of however many frames you asked for, plus a video file. If you've ever wanted a particle background, smoke plume, or animated texture plate to feed into img2img, a video-to-video pass, or an AnimateDiff-style pipeline, this is the kind of thing that normally forces you to leave ComfyUI for Blender or After Effects. This one keeps you on the graph.
It's also brand new with essentially zero community footprint yet, so treat the details below as "read the source, not the hype."
How it actually works
The clever (and slightly fragile) part: the capture happens in your browser, not the server. Drop the node on the graph and a frontend extension injects an iframe that loads the studio from /particleboy/app. The studio is a real WebGL engine - it ships Draco and Basis decoders for GLB import, so you can drop in emitter, collider, and force-field meshes, or a camera path.
Here's the flow, straight from web/particleboy.js and storage.py:
- Queue Prompt is hooked. Before the queue runs, the node posts a capture message to the iframe with your
frame_count,fps,width,height, and the Viewport/Camera toggle. - The studio simulates and captures each frame with GPU
readPixels- the real framebuffer, not a flaky canvas snapshot - and uploads each frame as a base64 PNG toPOST /particleboy/upload. - The backend stashes a PNG sequence under
ComfyUI/input/particleboy/<node_id>/frame_00001.pngand writes ameta.jsonwith the fps. - The node's
render()loads that sequence, resizes to yourwidth×height, and stacks the frames into oneIMAGEtensor.
The inputs and outputs that matter
Five widgets do the real work:
- width / height (default 1280×720, 256–4096, step 8) - capture resolution. Same step-8 habit as everywhere else in ComfyUI: keep it a multiple of 8.
- frame_count (default 24, 1–120) - how long the clip is. 24 frames at 24 fps is a one-second loop; crank it for a real shot.
- fps (default 24, 8–60) - playback rate of the recorded clip.
- use_camera (labeled Viewport off / Camera on) - off means the output matches the orbit view you're looking at; on means it uses the shot camera, from an imported GLB camera path or the locked default.
Ignore node_key - it's auto-synced to the node's id so captures land in the right folder; the UI hides it.
Two outputs:
- frames (
IMAGE) - the batch of frames. Wire this to Preview Image, Save Image, or Video Helper Suite. This is the one you'll actually use. - video (
STRING) - a file path. Ifffmpegis on your PATH you get an MP4 (libx264, CRF 18, faststart) written toComfyUI/output/particleboy/<node_id>.mp4; otherwise it falls back to an animated WebP. Theframesoutput is the reliable one - treat the video path as a convenience.
Installing it
ComfyUI Manager is easiest: search for ComfyUI-particleBoy and install. Manual route:
cd ComfyUI/custom_nodes
git clone https://github.com/PRASENJEETANAND/ComfyUI-particleBoy
# restart ComfyUI
Then right-click the canvas → Add Node → ParticleBoy → ParticleBoy Studio. A starter graph is in workflows/particleboy.json - drag it in and you get the node wired to Preview and Save.
Good news: there are no pip dependencies. The requirements.txt is literally a comment - it uses torch, numpy, and Pillow that ComfyUI already has. The only optional piece is ffmpeg on PATH for MP4 output instead of WebP. No model downloads, no heavy wheels.
Where people get burned
Because capture is browser-side, this node has a rule most ComfyUI nodes don't: the studio has to actually be rendered when you hit Queue Prompt. Queue with the node collapsed or scrolled out and you'll get a black/blank output - the README's own troubleshooting entry. If you do, re-run with the node open and visible. If the iframe never appears at all, a plain browser refresh isn't enough; restart ComfyUI so the web/particleboy.js extension loads. And if uploads 404, check the startup log - you should see [ParticleBoy] routes ready, and if you don't, the install is incomplete.
One design quirk worth knowing: it's not headless. No server-only rendering here - you need the UI open for this to work at all, which makes it awkward for API-driven or background batch jobs. It's a playground node, and it's happiest when you're right there playing with it.
Inputs (6)
| Name | Type | Default | Description |
|---|---|---|---|
| width | INT | 1280256–4096 | — |
| height | INT | 720256–4096 | — |
| frame_count | INT | 241–120 | — |
| fps | INT | 248–60 | — |
| use_camera | BOOLEAN | false | — |
| node_keyopt | STRING | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| frames | IMAGE | — |
| video | STRING | — |