Add camera motion first last frame
Create a continuous shot that starts and ends with the two images you provide.
워크플로 다운로드Cloud에서 사용해 보기 API 문서
00:00
워크플로 내부
소스 템플릿의 읽기 전용 미리보기입니다. Cloud에서 열어 노드를 살펴보고 변경할 수 있습니다.
Loading the graph
Open full-size workflow preview코드에서 이 모델 호출하기
아래 요청은 Playground와 동일하게 준비된 그래프와 설정을 사용합니다. 제출할 때마다 유료 실행이 시작될 수 있으므로 결과를 알 수 없는 제출을 자동으로 재시도하지 마세요.
1 API 키 가져오기 ↗
What you need
- Runs on
- Comfy Cloud
- 키
- COMFY_API_KEY
- 내 파일
- 코드가 해당 URL에서 업로드
유료 Cloud 요금제와 크레딧이 필요합니다.
# Python 3.10+: pip install comfy-sdk==0.4.0
import os
from comfy_sdk import Comfy
api_key = os.environ.get("COMFY_API_KEY", "").strip()
if not api_key: raise RuntimeError("Set COMFY_API_KEY")
os.environ.setdefault("COMFY_BASE_URL", "https://cloud.comfy.org")
client = Comfy(api_key=api_key)
workflow = client.workflows.from_json({
"31": {
"class_type": "LoadImage",
"inputs": {
"image": "UPLOADED_start_image_FILENAME"
},
"_meta": {
"title": "Load First Frame"
}
},
"39": {
"class_type": "LoadImage",
"inputs": {
"image": "UPLOADED_end_image_FILENAME"
},
"_meta": {
"title": "Load Last Frame"
}
},
"68": {
"class_type": "SaveVideo",
"inputs": {
"filename_prefix": "video/ltx2.3_flf2v",
"format": "auto",
"format.codec": "auto",
"video": [
"129:122",
0
]
},
"_meta": {
"title": "Save Video"
}
},
"129:100": {
"class_type": "RandomNoise",
"inputs": {
"noise_seed": 315253765879496
},
"_meta": {
"title": "RandomNoise"
}
},
"129:101": {
"class_type": "LTXVEmptyLatentAudio",
"inputs": {
"audio_vae": [
"129:126",
0
],
"batch_size": 1,
"frame_rate": [
"129:114",
0
],
"frames_number": [
"129:130",
1
]
},
"_meta": {
"title": "Empty LTXV Latent Audio"
}
},
"129:102": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 5
},
"_meta": {
"title": "Duration"
}
},
"129:103": {
"class_type": "LTXAVTextEncoderLoader",
"inputs": {
"ckpt_name": "ltx-2.3-22b-distilled-fp8.safetensors",
"device": "default",
"text_encoder": "gemma_3_12B_it_fp4_mixed.safetensors"
},
"_meta": {
"title": "Load LTXV Audio Text Encoder"
}
},
"129:104": {
"class_type": "LTXVPreprocess",
"inputs": {
"image": [
"129:124",
0
],
"img_compression": 25
},
"_meta": {
"title": "LTXV Preprocess"
}
},
"129:105": {
"class_type": "VAEDecodeTiled",
"inputs": {
"overlap": 64,
"samples": [
"129:106",
2
],
"temporal_overlap": 64,
"temporal_size": 4096,
"tile_size": 768,
"vae": [
"129:127",
2
]
},
"_meta": {
"title": "VAE Decode (Tiled)"
}
},
"129:106": {
"class_type": "LTXVCropGuides",
"inputs": {
"latent": [
"129:121",
0
],
"negative": [
"129:111",
1
],
"positive": [
"129:111",
0
]
},
"_meta": {
"title": "LTXVCropGuides"
}
},
"129:107": {
"class_type": "LTXVAudioVAEDecode",
"inputs": {
"audio_vae": [
"129:126",
0
],
"samples": [
"129:121",
1
]
},
"_meta": {
"title": "LTXV Audio VAE Decode"
}
},
"129:108": {
"class_type": "EmptyLTXVLatentVideo",
"inputs": {
"batch_size": 1,
"height": [
"129:110",
1
],
"length": [
"129:130",
1
],
"width": [
"129:110",
0
]
},
"_meta": {
"title": "Empty LTXV Latent Video"
}
},
"129:109": {
"class_type": "LTXVConditioning",
"inputs": {
"frame_rate": [
"129:123",
0
],
"negative": [
"129:112",
0
],
"positive": [
"129:128",
0
]
},
"_meta": {
"title": "LTXVConditioning"
}
},
"129:110": {
"class_type": "GetImageSize",
"inputs": {
"image": [
"129:124",
0
]
},
"_meta": {
"title": "Get Image Size"
}
},
"129:111": {
"class_type": "LTXVAddGuide",
"inputs": {
"frame_idx": -1,
"image": [
"129:99",
0
],
"latent": [
"129:115",
2
],
"negative": [
"129:115",
1
],
"positive": [
"129:115",
0
],
"strength": 0.7,
"vae": [
"129:127",
2
]
},
"_meta": {
"title": "LTXVAddGuide"
}
},
"129:112": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"129:103",
0
],
"text": "blurry, out of focus, overexposed, underexposed, low contrast, washed out colors, excessive noise, grainy texture, poor lighting, flickering, motion blur, distorted proportions, unnatural skin tones, deformed facial features, asymmetrical face, missing facial features, extra limbs, disfigured hands, wrong hand count, artifacts around text, unreadable text on shirt or hat, incorrect lettering on cap (“PNTR”), incorrect t-shirt slogan (“JUST DO IT”), missing microphone, misplaced microphone, inconsistent perspective, camera shake, incorrect depth of field, background too sharp, background clutter, distracting reflections, harsh shadows, inconsistent lighting direction, color banding, cartoonish rendering, 3D CGI look, unrealistic materials, uncanny valley effect, incorrect ethnicity, wrong gender, exaggerated expressions, smiling, laughing, exaggerated sadness, wrong gaze direction, eyes looking at camera, mismatched lip sync, silent or muted audio, distorted voice, robotic voice, echo, background noise, off-sync audio, missing sniff sounds, incorrect dialogue, added dialogue, repetitive speech, jittery movement, awkward pauses, incorrect timing, unnatural transitions, inconsistent framing, tilted camera, missing door or shelves, missing shallow depth of field, flat lighting, inconsistent tone, cinematic oversaturation, stylized filters, or AI artifacts."
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"129:113": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 1280
},
"_meta": {
"title": "Width"
}
},
"129:114": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 25
},
"_meta": {
"title": "Frame Rate(int)"
}
},
"129:115": {
"class_type": "LTXVAddGuide",
"inputs": {
"frame_idx": 0,
"image": [
"129:104",
0
],
"latent": [
"129:108",
0
],
"negative": [
"129:109",
1
],
"positive": [
"129:109",
0
],
"strength": 0.7,
"vae": [
"129:127",
2
]
},
"_meta": {
"title": "LTXVAddGuide"
}
},
"129:116": {
"class_type": "CFGGuider",
"inputs": {
"cfg": 1,
"model": [
"129:127",
0
],
"negative": [
"129:111",
1
],
"positive": [
"129:111",
0
]
},
"_meta": {
"title": "CFG Guider"
}
},
"129:117": {
"class_type": "SamplerEulerAncestral",
"inputs": {
"eta": 0,
"s_noise": 1
},
"_meta": {
"title": "SamplerEulerAncestral"
}
},
"129:118": {
"class_type": "ManualSigmas",
"inputs": {
"sigmas": "1., 0.99375, 0.9875, 0.98125, 0.975, 0.909375, 0.725, 0.421875, 0.0"
},
"_meta": {
"title": "ManualSigmas"
}
},
"129:119": {
"class_type": "LTXVConcatAVLatent",
"inputs": {
"audio_latent": [
"129:101",
0
],
"video_latent": [
"129:111",
2
]
},
"_meta": {
"title": "Concat AV Latent"
}
},
"129:120": {
"class_type": "SamplerCustomAdvanced",
"inputs": {
"guider": [
"129:116",
0
],
"latent_image": [
"129:119",
0
],
"noise": [
"129:100",
0
],
"sampler": [
"129:117",
0
],
"sigmas": [
"129:118",
0
]
},
"_meta": {
"title": "SamplerCustomAdvanced"
}
},
"129:121": {
"class_type": "LTXVSeparateAVLatent",
"inputs": {
"av_latent": [
"129:120",
1
]
},
"_meta": {
"title": "Separate AV Latent"
}
},
"129:122": {
"class_type": "CreateVideo",
"inputs": {
"audio": [
"129:107",
0
],
"bit_depth": "auto",
"codec": "none",
"color_space": "sRGB",
"fps": [
"129:123",
0
],
"images": [
"129:105",
0
]
},
"_meta": {
"title": "Create Video"
}
},
"129:123": {
"class_type": "ComfyMathExpression",
"inputs": {
"expression": "a",
"values.a": [
"129:114",
0
]
},
"_meta": {
"title": "Math Expression"
}
},
"129:124": {
"class_type": "ResizeImageMaskNode",
"inputs": {
"input": [
"31",
0
],
"resize_type": "scale dimensions",
"resize_type.crop": "center",
"resize_type.height": [
"129:98",
0
],
"resize_type.width": [
"129:113",
0
],
"scale_method": "nearest-exact"
},
"_meta": {
"title": "Resize Image/Mask"
}
},
"129:125": {
"class_type": "ResizeImageMaskNode",
"inputs": {
"input": [
"39",
0
],
"resize_type": "scale dimensions",
"resize_type.crop": "center",
"resize_type.height": [
"129:98",
0
],
"resize_type.width": [
"129:113",
0
],
"scale_method": "nearest-exact"
},
"_meta": {
"title": "Resize Image/Mask"
}
},
"129:126": {
"class_type": "LTXVAudioVAELoader",
"inputs": {
"ckpt_name": "ltx-2.3-22b-distilled-fp8.safetensors"
},
"_meta": {
"title": "Load LTXV Audio VAE"
}
},
"129:127": {
"class_type": "CheckpointLoaderSimple",
"inputs": {
"ckpt_name": "ltx-2.3-22b-distilled-fp8.safetensors"
},
"_meta": {
"title": "Load Checkpoint"
}
},
"129:128": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"129:103",
0
],
"text": "The camera move from a high position to a low position, keeping the character in the frame centered.\nMusic: Synthwave cyberpunk music with calm ambient synths and driving 80s beats."
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"129:130": {
"class_type": "ComfyMathExpression",
"inputs": {
"expression": "a * b + 1",
"values.a": [
"129:102",
0
],
"values.b": [
"129:114",
0
]
},
"_meta": {
"title": "Math Expression"
}
},
"129:98": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 720
},
"_meta": {
"title": "height"
}
},
"129:99": {
"class_type": "LTXVPreprocess",
"inputs": {
"image": [
"129:125",
0
],
"img_compression": 25
},
"_meta": {
"title": "LTXV Preprocess"
}
}
})
workflow.set_input("39", "image", client.assets.from_url("https://cdn.jsdelivr.net/gh/Comfy-Org/workflow_templates@90c71fb78b3726392d010ff62a8e79e92d7296ad/input/low_view_classic_car.png"))
workflow.set_input("31", "image", client.assets.from_url("https://cdn.jsdelivr.net/gh/Comfy-Org/workflow_templates@90c71fb78b3726392d010ff62a8e79e92d7296ad/input/high_view_classic_car.png"))
# run() also passes api_key to the partner nodes in this workflow.
job = client.run(workflow, api_key=api_key)
for output in job.get_outputs("68"):
output.to_file(output.name)