lucataco/split-screen-video ❓🖼️✓ → 🖼️

▶️ 78 runs 📅 Jul 2025 ⚙️ Cog 0.15.9 🔗 GitHub
video-editing video-to-video

About

Combines two videos into a single split-screen layout

Example Output

Output

Performance Metrics

1.53s Prediction Time
54.94s Total Time
All Input Parameters
{
  "layout": "top and bottom",
  "video_1": "https://replicate.delivery/pbxt/NIJ08Z2RJQDsHD28FVxoCPh77kF7ZNzjMfjU3aHK9UQqdjyd/replicate-prediction-kpgjjgx3v9rm80cqrwjva6xcvm.mp4",
  "video_2": "https://replicate.delivery/pbxt/NIJ08cwSnYp8cW7OG2ihkpCInrfXRW8cC2u731MO6HJI6m7Y/replicate-prediction-pg7wcbzh05rm80cqrwkamxz58g.mp4",
  "loop_videos": true,
  "audio_source": "video 1",
  "quality_preset": "fast",
  "duration_source": "video 1"
}
Input Parameters
layout Default: left and right
Layout for combining videos
video_1 (required) Type: string
First video file
video_2 (required) Type: string
Second video file
loop_videos Type: booleanDefault: true
Loop shorter video to match duration
audio_source Default: video 1
Which video's audio to use
quality_preset Default: fast
Speed vs quality tradeoff
duration_source Default: video 1
Which video's duration to use
Output Schema

Output

Type: stringFormat: uri

Example Execution Logs
Video 1 duration: 5.04s, needs loop: False
Video 2 duration: 5.04s, needs loop: True
Target duration: 5.04s
Generated filter complex: [1:v]loop=loop=-1:size=32767:start=0[v2_looped];[0:v]scale=970:532:flags=fast_bilinear,fps=30[v1_final];[v2_looped]scale=970:546:flags=fast_bilinear,fps=30[v2_final];[v1_final][v2_final]vstack=inputs=2[output]
No audio streams found in either video, creating silent audio track
Full FFmpeg command: ffmpeg -y -threads 8 -i /tmp/tmp473_4he6replicate-prediction-kpgjjgx3v9rm80cqrwjva6xcvm.mp4 -i /tmp/tmp203pxdl0replicate-prediction-pg7wcbzh05rm80cqrwkamxz58g.mp4 -filter_complex [1:v]loop=loop=-1:size=32767:start=0[v2_looped];[0:v]scale=970:532:flags=fast_bilinear,fps=30[v1_final];[v2_looped]scale=970:546:flags=fast_bilinear,fps=30[v2_final];[v1_final][v2_final]vstack=inputs=2[output] -f lavfi -i anullsrc=channel_layout=stereo:sample_rate=48000 -map 2:a:0 -map [output] -t 5.042 -vsync cfr -r 30 -avoid_negative_ts make_zero -c:v libx264 -preset veryfast -crf 25 -x264-params scenecut=0:bframes=2:b-adapt=1:ref=1 -c:a aac -b:a 128k -ac 2 -movflags +faststart -fflags +genpts /tmp/tmprv9pbl0p.mp4
FFmpeg completed successfully using software acceleration
Version Details
Version ID
d2c098447f1c28bf1d8fbc7f11ec7c864ec7d32c26e3676aa6612ad8ce89f483
Version Created
July 3, 2025
Run on Replicate →