Am 26.02.2020 um 16:48 schrieb Michael Koch:
Hi,

I'd like to know if someone can reproduce this problem:

Make a 6s video with audio:
ffmpeg -f lavfi -i testsrc2=size=vga -f lavfi -i sine=1000 -t 6 -y video.mp4
The video plays correctly and has 6s of audio.

Now mix the audio channels from two of these input videos:
ffmpeg -i video.mp4 -i video.mp4 -lavfi "[0:a][1:a]amix=weights='1.0 0.1'" -y out.mp4

You can hear that the audio from the first input ends too early at 4s, and the audio from the second input has the correct length 6s.
Tested with FFplay and VLC.

Known workaround: add -c:v mpeg4

This is ticket 8489, but so far nobody did have a look at it.

Another workaround is to pad a single audio sample to the end of the first input: ffmpeg -i video.mp4 -i video.mp4 -lavfi "[0:a]apad=pad_len=1[p];[p][1:a]amix=weights='1.0 0.1'" -y out.mp4

Michael

_______________________________________________
ffmpeg-user mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".

Reply via email to