Wan Camera Embedding Advanced
6DoF, eased, chainable paths
- previous_camera_path
- camera_embedding
- width
- height
- length
- camera_path
The stock Wan image-to-video workflow gives you a camera checkbox, a direction dropdown, and a lot of hoping. Wan 2.1 and 2.2 know how to move a camera - video training taught them real 3D - but the native WanCameraEmbedding node only lets you nudge a handful of preset moves. This node is the "fine, I'll do it myself" answer: independent translation and rotation on every axis, easing between values, and a path-chaining trick that turns one 5-second clip into a continuous, hand-built camera run.
It's the flagship of thepororo's small Wan Camera Advanced pack (GPL-3.0, no dependencies to pip-install), and it produces the same WAN_CAMERA_EMBEDDING type ComfyUI's native node does - so nothing else in your workflow changes. You swap the camera source, not the pipeline.
How it works
Under the hood it reuses ComfyUI's own camera-trajectory machinery: the node builds a per-frame rotation+translation matrix for every frame, then feeds it through process_pose_params from comfy_extras.nodes_camera_trajectory - the exact encoder the native node uses. That's why its output drops straight into WanCameraImageToVideo's camera_conditions input, and why the frames get packed four-at-a-time into Wan's 3D causal VAE latent format.
The math is straightforward: you give it final translation and rotation values, and it interpolates from zero to those values across length frames, applying whatever easing you picked. Default is ease_in_out, which means the camera glides to a stop instead of slamming to the end. That single choice is why paths from this node read as "cinematic" where preset moves read as "slideshow."
The inputs that matter
Most of them are self-explanatory, but these are the ones you'll actually set:
translate_x/translate_y/translate_z- truck (left-right), pedestal (up-down), dolly (in-out). The author's own starting values: truck right istranslate_x = 0.3; a dolly-then-pan tracking shot istranslate_x = 0.2withrotate_y_deg = -8. Yaw right starts atrotate_y_deg = 15.rotate_x_deg/rotate_y_deg/rotate_z_deg- pitch, yaw, roll.speed- scales everything.translation_scaledefaults to 1.5 androtation_scaleto 1.0, so the numbers you type are already "reasonable move" sized.length- frame count, and here's the trap: it must be 1 plus a multiple of 4 (81 default, 121 for ~7.5s). The node hard-errors otherwise. This isn't pedantry - it's the 4-frame VAE packing.easing-linear,ease_in,ease_out, orease_in_out.
The optional fx/fy/cx/cy inputs are camera intrinsics (focal length and principal point, normalized to 0–1). Leave them at 0.5 unless you know why you're changing them; the docs exist for a reason and this isn't it.
Outputs: camera_embedding (wire to camera_conditions), plus width, height, and length pass-throughs (handy for feeding downstream nodes that want plain ints), and camera_path - the key to chaining.
Chaining: the feature that sells it
The previous_camera_path optional input is what makes this pack more than a slider array. Connect one node's camera_path into the next node's previous_camera_path, and the second segment starts exactly where the first ended - the transforms compose, and the shared boundary frame is counted once, so three 41-frame segments give you 121 frames, not 123. Want a push-in, then a yaw, then a dolly-out in one continuous shot? Chain three nodes, each with its own easing. The one real constraint: every chained segment must use the same width, height, and intrinsics, or it throws a clear error.
Install and troubleshooting
cd ComfyUI/custom_nodes
git clone https://github.com/thepororo/ComfyUI-WanCameraAdvanced.git
Restart ComfyUI. In ComfyUI Manager, search "Wan Camera Advanced." That's the whole install - pyproject.toml declares zero dependencies, and it leans on torch/numpy plus ComfyUI's own camera-trajectory code, so nothing to download and no model files.
Two gotchas worth knowing before they bite. First, big rotations ask the model to invent scene content that isn't in your source image - past about 45 degrees you'll get warping or hallucinated background. The fix is the pack's multi-frame reference node, which lets you supply perspective-consistent middle and end frames. Second, "left" and "right" are from the camera's point of view, and it's easy to spend ten minutes discovering your truck goes the wrong way - negative the translate_x or rotate_y_deg and move on with your life.
If your output is a static drift or a slide, check length first, then check your easing. ease_in_out on a fast speed can read almost like a dead stop mid-shot; linear is often the better look for pure dolly moves.
Inputs (18)
| Name | Type | Default | Description |
|---|---|---|---|
| width | INT | 83216–16384 | — |
| height | INT | 48016–16384 | — |
| length | INT | 811–16384 | — |
| translate_x | FLOAT | 0.00-4–4 | — |
| translate_y | FLOAT | 0.00-4–4 | — |
| translate_z | FLOAT | 0.00-4–4 | — |
| rotate_x_deg | FLOAT | 0.0-180–180 | — |
| rotate_y_deg | FLOAT | 0.0-180–180 | — |
| rotate_z_deg | FLOAT | 0.0-180–180 | — |
| speed | FLOAT | 1.000–10 | — |
| translation_scale | FLOAT | 1.500–10 | — |
| rotation_scale | FLOAT | 1.000–10 | — |
| easing | COMBO | ease_in_out | 4 options: linear, ease_in, ease_out, ease_in_out |
| previous_camera_pathopt | WAN_CAMERA_PATH | — | |
| fxopt | FLOAT | 10–1 | — |
| fyopt | FLOAT | 10–1 | — |
| cxopt | FLOAT | 0.500–1 | — |
| cyopt | FLOAT | 0.500–1 | — |
Outputs (5)
| Name | Type | Description |
|---|---|---|
| camera_embedding | WAN_CAMERA_EMBEDDING | — |
| width | INT | — |
| height | INT | — |
| length | INT | — |
| camera_path | WAN_CAMERA_PATH | — |