0

I am very new to FFmpeg.
I am trying to cut a portion of a video and hardcode the subtitle of that same portion in the output file.
My command is:

ffmped -ss 01:01:00.0 -i input.mp4 -vf subtitles=input.srt -t 00:02:00.0 output.mp4

I get the output of that portion with a hardcoded subtitile, however the subtitle is from the beginning of the file, not the subtitle starting from 01:01:00.0.

What am I doing wrong?

0

FFmpeg normalizes timestamps to start from 0 after seeking. So workaround is to copy timestamps and then set output ss to exclude unwanted portion of input.

ffmpeg -ss 01:01:00.0 -copyts -i input.mp4 -vf subtitles=input.srt -ss 01:01:00.0 -t 00:02:00.0 output.mp4

Your Answer

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