RT to camposes
Turn raw rotation/translation tensors into cameras 3D-Pack can orbit
- rotation
- translation
- orbit_radius
- CamPos
Most ComfyUI 3D renderers and samplers don't take camera matrices - they take orbit poses: [orbit radius, elevation, azimuth, center X, center Y, center Z] per view. RT to camposes (from ComfyUI-3D-MeshTool) converts your rotation and translation tensors into exactly that format, so a custom camera path becomes something a 3D-Pack-style renderer can actually consume.
It's the bridge between the "math side" of the pack (tensors from json-to-campos, tensor-new, the array tools) and the "render side" (nodes that expect ORBIT_CAMPOSES).
How it works
Give it two tensors with one row per camera view:
rotation(Tensor) -[N, 3], with elevation and azimuth in the first two columnstranslation(Tensor) -[N, 3], the orbit center for each view
It first checks the two counts match - if not, it prints an error and returns nothing, so the mismatch is visible in the console rather than silent. Then it reshuffles the columns: the orbit radius goes into column 0, elevation into column 1, azimuth into column 2, and the translation sits in the last three. The result is [N, 6] rows in the ORBIT_CAMPOSES convention.
The optional orbit_radius tensor lets you supply per-view radii. Leave it unconnected and every camera gets a default radius of 1.75 - which is why naive RT-to-camposes output orbits everything at the same distance. If you want the camera to swing in close on some views, feed that tensor.
Output
CamPos(ORBIT_CAMPOSES) - the[N, 6]pose list, ready for a 3D-Pack renderer or camera-mover node.
Install
It ships in ComfyUI-3D-MeshTool:
cd ComfyUI/custom_nodes
git clone https://github.com/807502278/ComfyUI-3D-MeshTool
cd ComfyUI-3D-MeshTool
pip install -r requirements.txt
Restart ComfyUI (or install via ComfyUI Manager, search "ComfyUI-3D-MeshTool").
Common issues
The two that bite: count mismatches, which fail loudly in the console, and angle convention drift. This node passes rotation values through mostly untouched (it rearranges columns, not units), so if your rotation tensor is in radians and downstream expects degrees, apply the conversion upstream - that's exactly what json-to-campos's to_angle toggle does for you. Also note there's no error if you pass a zero-length rotation; you'll get a degenerate pose set, so validate your tensors before wiring them in.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| rotation | Tensor | — | |
| translation | Tensor | — | |
| orbit_radiusopt | Tensor | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| CamPos | ORBIT_CAMPOSES | — |