User Tools

Site Tools


ffmpeg:subtitles:add_subtitles_from_another_file

This is an old revision of the document!


ffmpeg - Subtitles - Add subtitles from another file

Assuming a.mkv contains only the video and audio, but b.mkv contains subtitle data to be included.

ffmpeg -i a.mkv -i b.mkv -c:v copy -c:a copy -c:s copy -map 0:0 -map 0:1 -map 1:2 -y out.mkv

NOTE: To determine the mapping for the subtitle, run:

ffmpeg -i b.mkv

and see which stream contains the subtitle data.

ffmpeg/subtitles/add_subtitles_from_another_file.1735587132.txt.gz · Last modified: 2024/12/30 19:32 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki