Nodes/ComfyUI_Adforge/Vertex Veo First-Last Frame to Video
ComfyUI Node

Vertex Veo First-Last Frame to Video

Give Veo two keyframes and it'll shoot the scene between them

By Creditas-labs·Created 10 months ago·Updated 9 months ago· 1
Vertex Veo First-Last Frame to Video
  • first_frame_image
  • last_frame_image
  • videos
  • video_path_list
prompt
first_frame_gcs_uri
last_frame_gcs_uri
negative_prompt
output_gcs_uriNone/videos/video-first-last-frame-20260720-202149.mp4
modelveo-3.1-generate-preview
aspect_ratio16:9
first_frame_mime_typeimage/png
last_frame_mime_typeimage/png
duration_seconds8
resolution1080p
fps24
seed0
number_of_videos1
enhance_prompttrue
generate_audiofalse
person_generationallow_adult

Animating between two fixed frames is one of those things local video models are still clumsy at - you feed them a start and an end image and hope they don't morph your subject into a puddle of pixels. Veo is genuinely good at it, which is why the first-last-frame pattern has become a staple for product shots and looping clips. This node from the Adforge pack is the cleanest way to do it inside ComfyUI: plug in a first frame and a last frame, write a prompt, and Google's Veo generates the in-between motion, up to 10 seconds.

It's part of Creditas' ad-creation toolkit, sitting alongside its siblings in AdForge/Video Generation (Extend Video, Image to Video, Video with Reference). If you've got a hero image and a payoff image and you need the transition - a can of soda that's sealed at frame one and open at frame two, say - this is the node you reach for. No GPU load locally; the actual generation happens on Google's Vertex AI, so the only heavy thing on your machine is the network bill.

How it works

The node uses Google's Gen AI SDK (google-genai). Your two frames become Image objects - either uploaded as bytes from the IMAGE sockets or referenced by GCS URI - and Veo treats the first frame as the source image while the last frame is passed as the last_frame parameter. The model interpolates the motion between them, guided by your prompt. Then the node polls the async operation every five seconds and, when it's done, downloads the resulting clips from GCS into your ComfyUI output folder and hands them back as VIDEO values.

The inputs that matter

  • prompt (required) - describes what happens between the frames. This is what keeps the motion coherent.
  • first_frame_image and last_frame_image - IMAGE sockets; wire them from any image-producing node. Or use the first_frame_gcs_uri / last_frame_gcs_uri string inputs instead if your frames already live in the bucket.
  • model - defaults to veo-3.1-generate-preview, and the dropdown also offers the fast 3.1 variant, the Veo 3 and Veo 2 options. Frames land on the image side, so the newer models handle them best.
  • duration_seconds - 1 to 10, default 8. How long the interpolation runs.
  • fps (default 24), seed (0 = random, set one for reproducibility), number_of_videos (1–4 variations), generate_audio (Veo 3's native audio, off by default).
  • enhance_prompt (default on) - rewrites your prompt via Gemini before generation. Nice for quality, but it's an extra API call.
  • first_frame_mime_type / last_frame_mime_type - image/png by default, which matches what the IMAGE socket produces.

Outputs

Same shape as the rest of the pack: videos (a list of VIDEO clips you can preview or feed forward) and video_path_list (the local file paths to those clips).

Installing and setting it up

Install via ComfyUI Manager (search adforge) or manually:

cd ComfyUI/custom_nodes
git clone https://github.com/Creditas-labs/ComfyUI_Adforge
cd ComfyUI_Adforge
pip install -r requirements.txt   # or: uv pip install -r requirements.txt

Restart ComfyUI, then set up Google Cloud credentials in a .env under ComfyUI/custom_nodes/comfyui_adforge (copy the repo's .env.example), or export them: GOOGLE_CLOUD_PROJECT, GOOGLE_CLOUD_STORAGE_BUCKET, GOOGLE_CLOUD_LOCATION, and API_KEY (or a service-account path in GOOGLE_APPLICATION_CREDENTIALS). The pack needs Python 3.12+ and a recent ComfyUI because it's built on the new comfy_api node API.

Where people get burned

The node is strict about pairing: it wants both frames from the same source. The source code throws a ValueError if you mix an image socket with a GCS URI, or provide only one frame - "Either both images or both GCS URIs must be provided." The other common failure is the usual Adforge trap: no writable, billed GCS bucket. The output has to be staged in cloud storage before it's downloaded locally, so if GOOGLE_CLOUD_STORAGE_BUCKET is wrong or the project isn't billed, you'll get a cryptic generation failure. Set a seed if you want the same animation back - Veo respects seeds when nothing else changes.

CategoryAdForge/Video Generation

Inputs (19)

NameTypeDefaultDescription
promptSTRINGThe text prompt used to guide video generation.
first_frame_imageoptIMAGENo documentation available
last_frame_imageoptIMAGENo documentation available
first_frame_gcs_urioptSTRINGNo documentation available
last_frame_gcs_urioptSTRINGNo documentation available
negative_promptoptSTRINGOptional. A text string that describes anything you want to discourage the model from generating.
output_gcs_urioptSTRINGNone/videos/video-first-last-frame-20260720-202149.mp4GCS URI where the generated videos will be stored, in the format 'gs://BUCKET_NAME/SUBDIRECTORY'.
modeloptCOMBOveo-3.1-generate-previewThe Veo model to use for video generation.
aspect_ratiooptCOMBO16:9Optional. Specifies the aspect ratio of generated videos.
first_frame_mime_typeoptCOMBOimage/pngMime type of the input image or video, e.g., 'image/png' or 'video/mp4'.
last_frame_mime_typeoptCOMBOimage/pngMime type of the input image or video, e.g., 'image/png' or 'video/mp4'.
duration_secondsoptINT81–10Required. The length in seconds of video files that you want to generate.
resolutionoptCOMBO1080pOptional. Veo 3 models only. The resolution of the generated video.
fpsoptINT241–60Optional. Frames per second for the generated video.
seedoptINT00–2147483647Optional. A number to request to make generated videos deterministic. Adding a seed number with your request without changing other parameters will cause the model to produce the same videos.
number_of_videosoptINT11–4Optional. Number of video variations to generate.
enhance_promptoptBOOLEANtrueOptional. Use Gemini to enhance your prompts.
generate_audiooptBOOLEANfalseGenerate audio for the video.
person_generationoptCOMBOallow_adultOptional. The safety setting that controls whether people or face generation is allowed.

Outputs (2)

NameTypeDescription
videosVIDEOA list of generated videos (VIDEO type).
video_path_listSTRINGA list of local paths to the generated videos (when output_format=local_file)