Open rsnitsch opened 1 year ago
Addendum: The issue is both present in version 0.1.0
(which I accidentally used first, see #733) and in the latest version av1an 0.4.1-unstable (rev 05fcb0b) (release)
.
Problem: My input video has a FPS of 30.
No, ffmpeg shows 30.23 fps and that is an indicator that it was encoded with variable framerate. That is ok if this file will be your final result and you want small file size. In general it's not worth it, you'll run into all sort of problems, if you need to touch it again.
Check with mediainfo Parade.mp4
, it should say variable fps etc.
Whatever encoded Parade.mp4 (Microsoft Game DVR?), set it to constant framerate and use constant framerate everywhere to avoid such problems in the future.
If this was indeed ingame-recording and you play on 60fps, then 60fps would be correct as intended.
I don't know how to fiddle this with av1an, but with ffmpeg it would be:
ffmpeg -i input.mp4 -r 60 output.mp4 <- this keeps the duration, keep everything synced and 60fps are enforced as output to the encoder (slight glitches are possible, because the input is already garbled aka variable fps :) )
don't be confused with
ffmpeg -r 60 -i input output.mp4 <- stretch/squeeze the duration. 30,23fps (30,23*6,36 seconds gives ~192 single images total) playback in 60fps is ~50% duration aka playback in 2x speed (this happened for out4.mp4)
I am running av1an via Docker within WSL2 on Windows 11.
For example with this command:
Problem: My input video has a FPS of 30. The output video has a FPS of 60 which means that after 50% the video stream ends while the audio is still playing.
ffprobe output for original video Parade.mp4:
ffprobe output for out4.mp4: