Nodes/KIE.ai Nodes Next/KIE • Camera Path
ComfyUI Node

KIE • Camera Path

Camera Path is a note to the model, not a camera rig

By felipederosilva·Created 2 months ago·Updated 3 days ago· 3
KIE • Camera Path
    • camera_direction
    • camera_path_json
    • top_view
    ◄path_modedolly►
    ◄duration_seconds5.0►
    ◄easingease in out►
    ◄start_x0.0►
    ◄start_y1.6►
    ◄start_z-4.0►
    ◄end_x0.0►
    ◄end_y1.6►
    ◄end_z-2.0►
    ◄look_at_x0.0►
    ◄look_at_y1.6►
    ◄look_at_z0.0►
    ◄mid_x1.0►
    ◄mid_y1.6►
    ◄mid_z-3.0►
    ◄orbit_degrees90►
    ◄keyframe_samples9►

    What it is

    KIE • Camera Path turns a move you can picture into two things a video model can actually consume: a sentence, and a block of keyframe JSON. Dolly in, orbit round the subject, crane up, or hand-place a curved path - then check the top-down map before you spend credits on a generation that ignores your intent.

    Here's the part the author is unusually honest about, and you should internalise it before you touch a slider: these coordinates are editorial intent, not native camera conditioning. Unless the model you're calling documents matching camera controls, "dolly in from 0,1.6,−4 to 0,1.6,−2" goes into the prompt as prose and the model does whatever it feels like. The node's own JSON says so: "application": "prompt_guidance_unless_model_adapter_documents_native_fields".

    So treat it as a way to write consistent, precise camera language across your shots.

    How it works

    You give it path_mode, a duration, an easing curve, a start point, an end point, a look_at target, and - depending on the mode - a midpoint or an orbit angle. The optional mid_x/mid_y/mid_z is the control point; orbit_degrees is how far around the subject you swing.

    It samples the trajectory into keyframe_samples steps (3 to 61, 9 by default). Coordinates are in metres-ish scene space, which is why the defaults are y = 1.6 - eye height. look_at stays fixed; the camera is what moves.

    The modes are:

    • dolly - straight interpolation start → end.
    • crane - also straight interpolation. Look at the source: crane and dolly share the same lerp; the difference is the mode name in the direction string and, in practice, that crane implies you're changing Y while dolly implies you're not. It's a naming convention with your own discipline behind it.
    • orbit - rotates around look_at by orbit_degrees, with Y interpolating separately. The midpoint is ignored here.
    • custom path - a quadratic Bézier through the midpoint, so the move curves.

    easing applies to the parameter before sampling: linear, ease in, ease out, ease in out (smoothstep). Easing is why a dolly doesn't feel like a robot.

    Inputs and outputs

    The three outputs are the whole point:

    • camera_direction - one sentence: mode, duration, easing, start and end positions, look-at target, plus the "treat these as editorial intent" caveat. Wire this into a video node's prompt, or into KIE • Variation Matrix's fixed constraints so every take keeps the same camera.
    • camera_path_json - schema-tagged keyframes with time_seconds, position, look_at. This is what you paste into KIE • Save Generation Recipe's camera_plan_json so a shot you liked is reproducible later.
    • top_view - a rendered 640×460 map, pink ring for look-at, green start, amber end, path drawn in blue. Saved to output/KIE-Camera/Path so it survives a reload.

    The node is an output node, so it always executes - the preview writes a PNG every run.

    Install

    cd ComfyUI/custom_nodes
    git clone https://github.com/felipederosilva/ComfyUI-KIE-Nodes-Next
    python -m pip install -r ComfyUI-KIE-Nodes-Next/requirements.txt
    

    It needs Pillow and numpy for the preview; no API key is required for this node, because it never calls KIE. Set the key once anyway if the rest of your graph is KIE nodes - Settings → KIE.ai Nodes Next → Connection.

    Where people get burned

    • Reading coordinates as centimetres. They're scene units. A start_z of −4 is four units back, not four metres of cable.
    • Assuming the model obeys. It usually won't, not literally. Short moves with clear subject framing work; a 30-second orbit of a face won't.
    • Forgetting the JSON is the artifact. The direction string is what the model reads today, but the JSON is what makes the shot reproducible. Save it with the recipe.
    • Out-of-range values. Duration is clamped to 0.5–120 s, orbit to ±360°, samples to 3–61. The node validates rather than silently clamping, so an out-of-range value is a hard error.
    CategoryKIE Next/Studio/Direction

    Inputs (17)

    NameTypeDefaultDescription
    path_modeCOMBOdolly4 options: custom path, dolly, orbit, crane
    duration_secondsFLOAT5.00.5–120—
    easingCOMBOease in out4 options: linear, ease in out, ease in, ease out
    start_xFLOAT0.0-1000–1000—
    start_yFLOAT1.6-1000–1000—
    start_zFLOAT-4.0-1000–1000—
    end_xFLOAT0.0-1000–1000—
    end_yFLOAT1.6-1000–1000—
    end_zFLOAT-2.0-1000–1000—
    look_at_xFLOAT0.0-1000–1000—
    look_at_yFLOAT1.6-1000–1000—
    look_at_zFLOAT0.0-1000–1000—
    mid_xoptFLOAT1.0-1000–1000—
    mid_yoptFLOAT1.6-1000–1000—
    mid_zoptFLOAT-3.0-1000–1000—
    orbit_degreesoptFLOAT90-360–360—
    keyframe_samplesoptINT93–61—

    Outputs (3)

    NameTypeDescription
    camera_directionSTRING—
    camera_path_jsonSTRING—
    top_viewIMAGE—