Mpv: How to add multiple overlays to a playlist?

Created on 8 Jun 2020  路  1Comment  路  Source: mpv-player/mpv

I'm trying to use both playlist and overlaying videos at the same time but it's not clear how to do it. What I've got:

  1. a bunch of front and rear video files from a dashcam in F and R directories
  2. a way to play e.g. all front files in a playlist: mpv F/*
  3. a way to play an overlay of rear view on top of front view: mpv $front_video --external-file=$rear_video --lavfi-complex='[vid2] scale=640x360 [small]; [vid1] [small] overlay [vo]'

What I don't understand is how to play all overlays in a playlist so I could jump back and forth, set the volume, playback speed, contrast, etc. The closest I got:

# when in F directory
mpv \
  REC_200607-175943F.MOV --external-file=../R/REC_200607-175943R.MOV --lavfi-complex='[vid2] scale=640x360 [small]; [vid1] [small] overlay [vo]' \
  GSR_200607-180444F.MOV --external-file=../R/GSR_200607-180444R.MOV --lavfi-complex='[vid2] scale=640x360 [small]; [vid1] [small] overlay [vo]' \
  GSR_200607-180943F.MOV --external-file=../R/GSR_200607-180943R.MOV --lavfi-complex='[vid2] scale=640x360 [small]; [vid1] [small] overlay [vo]'

But this way I only get the rear view from the first footage in all videos.

1st overlay, all fine:
2020-06-08-224634_2560x1440_escrotum

2nd overlay, rear view is from the 1st footage:
2020-06-08-224646_2560x1440_escrotum

It works well when I don't play them in a playlist but it's cumbersome.

Log file

overlays.log

question

Most helpful comment

>All comments

Was this page helpful?
0 / 5 - 0 ratings

Related issues

xanadupark picture xanadupark  路  3Comments

thebunnyrules picture thebunnyrules  路  3Comments

ghost picture ghost  路  3Comments

WoLpH picture WoLpH  路  3Comments

sant527 picture sant527  路  4Comments