0

I have this 3 hour long video which consists of:

< 1-5 seconds of black frames > -- < clip > -- < 1-5 seconds of black frames > -- < clip > -- ...

I could successfully get the clip without the black frames with the slow seek, but it takes over 4 minutes wall time just for seeking.

ffmpeg -y -i "C:\Users\user\Videos\obs\part1.mp4" -ss 4370.48 -to 4384.95 -c:a copy -c:v hevc_nvenc -rc vbr_hq -cq 19 -b:v 10000k -maxrate:v 12500k "C:\Users\user\Videos\obs\____delete1.mp4"

I tried using the fast seek which takes only 4 sec wall time. It does start at the correct frame, but it includes a 4 sec blackframe chunk at the end of the video. The output that should've been 14 sec long became 18 sec.

ffmpeg -y -ss 4370.48 -i "C:\Users\user\Videos\obs\part1.mp4" -to 14.47 -c:a copy -c:v hevc_nvenc -rc vbr_hq -cq 19 -b:v 10000k -maxrate:v 12500k "C:\Users\user\Videos\obs\____delete2.mp4"

My video has around 640 clips so it's impractical to wait that long just for seeking, and it'll only get worse when I'll be seeking at around the 2+ hour mark.

$ ffmpeg -version
ffmpeg version 4.3.1 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 10.2.1 (GCC) 20200726

Using -t results in the same 18 sec clip with blackframes.

time ffmpeg -y -ss 4370.48 -i "C:\Users\guzma\Videos\obs\part1.mp4" -t 14.47 -c:a copy -c:v hevc_nvenc -rc vbr_hq -cq 19 -b:v 10000k -maxrate:v 12500k "C:\Users\user\Videos\obs\____delete3.mp4"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.