Start b clip after mixer transition ends

113 Views Asked by At

I'm seeking to mix 2 clips, however, I'd like for clip2 to start after the mixer transition ends, not begins.

Essentially, this should mix clip1 with only clip2's frame 0.

I was wondering if there was a better alternative to my current workaround:

melt \
    clip1.mp4 \
    clip2.mp4 in=0 out=0 length=300 \
       -mix 300 -mixer luma \
    clip2.mp4

Perhaps there is something to pause clip2 at frame 0 for 300 frames?

(I'm doing this with 2 .mlt clips, but voiding the audio_index doesn't seem to work on mlt clips, thus I get a small audio jump for 1 frame, so this workaround isn't ideal)

1

There are 1 best solutions below

1
On

You cannot set audio_index on .mlt virtual clips because audio_index is a property of the avformat producer, but MLT XML is read by the xml producer. You can use the hold producer to hold a frame and mute audio. It defaults to 25 frames duration; so use out to override it:

melt clip1.mp4 hold:clip2.mp4 frame=0 out=299 -mix 300 -mixer luma clip2.mp4