Save Point Cloud
Writing N×7 clouds to disk as .ply or .npy, depending on who's reading
- model_3d
- viewport_state
- model_3d_info
- camera_info
- model_3d
- model_3d_info
- camera_info
- width
- height
Point clouds in camera-comfyUI are N×7 tensors - x, y, z, then RGB and alpha. SavePointCloud is how you get that tensor out of the graph and onto disk, in whichever of the two formats the pack supports: .ply or .npy. The choice is genuinely a "who's going to read this file" decision, and the README spells out the tradeoff plainly: .npy is fast and preserves the tensor exactly, .ply is the format every external 3D tool understands.
Use .npy when the cloud is staying inside the pipeline family - the pack's own LoadPointCloud reads it back in one step, byte-for-byte, no conversion, no loss. Use .ply when the destination is a human or a different program: open it in CloudCompare, Meshlab, Blender, or any point-cloud viewer, share it, or hand it to photogrammetry tooling. If you're doing iterative work, .npy in and out is the pragmatic default and you export .ply at the end when the cloud is final.
The inputs
- pointcloud - the
N×7tensor (x y z+ RGB + alpha). - save_as -
plyornpy, defaultply. - filename_prefix - default
ComfyUIPointCloud; supports%date:yyyy-MM-dd%-style format tokens, with a counter appended.
It's an output node - nothing comes out the right side, you just get a UI entry pointing at the written file in ComfyUI/output/.
How it works
The .ply path uses Open3D to write the cloud with positions and colors (and alpha, when present). If Open3D isn't available, it falls back to a plain ASCII PLY writer, so the node never hard-fails on a missing dependency - worth knowing if you ever see a warning in the console but a valid file anyway. .npy is a straight numpy.save of the tensor. Colors are clipped to 0–1 on the PLY path, which matches how the pack's color tensors are normalized.
Installing it
It's part of camera-comfyUI; install the pack once. Manager → Custom Nodes Manager → camera-comfyUI → Install → restart, or:
cd ComfyUI/custom_nodes
git clone https://github.com/Alexankharin/camera-comfyUI.git
cd camera-comfyUI && python install.py
No optional dependencies required - though installing the base requirements (which include Open3D) gets you the better PLY writer.
Common issues
- Colors look wrong in an external viewer - the pack normalizes color to 0–1, so check your viewer's expectations. Most handle it fine, some expect 0–255.
.plyopens but has no color - you fed a cloud without color columns (N×6or fewer). The pack expectsN×7; check upstream (DepthToPointCloudoutputs the full form).- Huge ASCII files - that's the fallback writer without Open3D; installing the pack's requirements gets the binary writer and smaller files.
Get it saved, then get it somewhere useful.
Inputs (7)
| Name | Type | Default | Description |
|---|---|---|---|
| model_3d | FILE_3D_POINT_CLOUD_ANY,FILE_3D_PLY | Point cloud file (.ply) | |
| filename_prefix | STRING | 3d/ComfyUI | — |
| viewport_state | LOAD_3D | — | |
| width | INT | 10241–4096 | — |
| height | INT | 10241–4096 | — |
| model_3d_infoopt | LOAD3D_MODEL_INFO | — | |
| camera_infoopt | LOAD3D_CAMERA | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| model_3d | FILE_3D_POINT_CLOUD_ANY | — |
| model_3d_info | LOAD3D_MODEL_INFO | — |
| camera_info | LOAD3D_CAMERA | — |
| width | INT | — |
| height | INT | — |