Nodes/Splat Loader/Load Splat & Viewport (Spark)
ComfyUI Node

Load Splat & Viewport (Spark)

Frame your Gaussian splat like it's a real camera — Load Splat & Viewport (Spark)

By brayevalerien·Created 2 months ago·Updated 2 months ago· 1
Load Splat & Viewport (Spark)
    • image
    • mask
    • camera_info
    • mesh_path
    • splat
    model_file
    width1024
    height1024
    fov35
    camera_type
    frames1
    splat_scale1.00
    viewport

    ComfyUI can load Gaussian splats out of the box - but only .ply files, and its core 3D viewer doesn't render splats correctly, so "framing a shot" was guesswork. Load Splat & Viewport (Spark) kills that loop: it loads a splat and gives you a real interactive viewport inside the node, powered by Spark, and the image it outputs is exactly the angle you framed - the capture comes from the viewport itself.

    It's the one node in the comfyui-splat-loader pack (called "Splat Loader" in Manager), and it's heavily inspired by ComfyUI's BETA "Load 3D & Animation" node, rebuilt for gaussian splats instead of meshes. If you're already making splats - via ComfyUI-3D-Pack, a world model, or a photogrammetry capture - this is the node that makes actually using them pleasant instead of cursed. It supports .spz, .ply, .splat, and .ksplat.

    How it works

    Two halves, glued by a hidden string. The frontend runs a three.js + Spark viewport inside the node - orbit, pan, zoom, plus a button to flip the splat upside down (.spz files tend to be y-down, and the default is pre-flipped). When you frame a view, the node renders it to ComfyUI and serializes your camera pose, FOV, camera type, and flip state into the viewport input - a JSON string you never touch by hand.

    On execute, the Python side reads that state, loads the captured frame(s), and parses the splat file using ComfyUI's own gaussian parsers (comfy_extras.nodes_gaussian_splat, the same code behind File3DToSplat). So the splat output is a first-class SPLAT tensor - not proprietary - and plugs straight into Render Splat or the other splat nodes. Camera pose is emitted as LOAD3D_CAMERA, matching the 3D node family.

    The one gotcha: the node won't run until you've opened it and framed a view - no viewport state means a No viewport capture error. It's an "open it, frame it, then hit queue" node, not a "set inputs and go" node.

    The inputs that actually matter

    The viewport field you can ignore. The rest:

    • model_file - dropdown of splat files in ComfyUI/input/3d, or hit Load file to upload one from disk into that folder.
    • width / height - the viewport resolution and the output resolution. Set these first; 1024 default, up to 4096.
    • fov - vertical field of view in degrees, perspective only (default 35).
    • camera_type - perspective or orthographic. Ortho is great for top-down or blueprint-ish views.
    • frames - 1 is a still. Set it to, say, 32 and you get a turntable: the camera orbits a full 360° and outputs a batch of images for a video node; negative values orbit the other way.
    • splat_scale - multiplier on each gaussian's size. Lower = crisper points, higher = fuller, softer surface. Tune it so splats fill the view without overlapping too much.

    There's also a bookmark system in the viewport - save a camera position plus all camera settings (type, FOV) and restore them later (rename or delete by hovering). Handy for locking a "hero shot".

    Outputs

    • image - your framed view, black background; a batch when frames > 1.
    • mask - splat coverage, white where the splat is, consistent with the other splat nodes; feeds compositing/background-removal.
    • camera_info (LOAD3D_CAMERA) - the camera used, compatible with the 3D node family.
    • mesh_path - input-relative path of the loaded file.
    • splat (SPLAT) - the loaded splat, ready for Render Splat or the other splat nodes.

    Installing it

    Via ComfyUI Manager, search Splat Loader and install. The prebuilt viewport is bundled on that path, so you don't need Node.js or any build step - just restart ComfyUI. Take that route; it's what 99% of people should do.

    Manual install is where the README hides a catch. Because the viewport is a built web app, a raw git clone does not include it - the web/ directory is gitignored. You need Node.js:

    cd ComfyUI/custom_nodes
    git clone https://github.com/brayevalerien/comfyui-splat-loader
    cd comfyui-splat-loader
    npm install
    npm run build
    

    That generates web/viewport.js, which the frontend loads, then restart ComfyUI and hard-refresh the browser. Note the asymmetry: Manager is zero-build, the clone path requires npm - a blank box where the viewport should be means you skipped the build. If you later edit the viewport source, rerun npm run build (or npm run watch to auto-rebuild); a browser hard refresh suffices, no server restart. There are zero Python dependencies - refreshingly light for a corner of the ecosystem (ComfyUI-3D-Pack, I'm looking at you) that usually ships compiled CUDA wheels.

    Troubleshooting

    • "No viewport capture" error - you queued without framing. Open the node, load a splat, set your angle, then run. The node is marked experimental in the source, and this is its most opinionated behavior.
    • Splat upside down - hit the flip button in the viewport toolbar; .spz files tend to be y-down.
    • Blank image output - no file loaded, or the viewport never captured.
    • Viewport blank after manual install - you skipped npm run build (above), or the browser cached the old page. Hard refresh.

    If you're doing anything with gaussian splats in ComfyUI and are tired of framing blind, this is the one to grab.

    Category3d/splat

    Inputs (8)

    NameTypeDefaultDescription
    model_fileCOMBO1 options: none
    widthINT10241–4096
    heightINT10241–4096
    fovFLOAT351–120Vertical field of view in degrees (perspective only).
    camera_typeCOMBO2 options: perspective, orthographic
    framesINT1-240–2401 = single still. >1 = turntable: the camera orbits a full 360 turn and outputs a batch of images for a Video node. Negative orbits the other way.
    splat_scaleFLOAT1.000.1–3Multiplier on each gaussian's size. Lower = crisper points, higher = fuller/softer surface.
    viewportSTRING

    Outputs (5)

    NameTypeDescription
    imageIMAGE
    maskMASK
    camera_infoLOAD3D_CAMERA
    mesh_pathSTRING
    splatSPLAT