Copy subtitle stream to an .mkv file

Questions involving a Windows version of FFmpeg.
Post Reply
ducke
Posts: 2
Joined: Sat Feb 15, 2020 11:06 am

Copy subtitle stream to an .mkv file

Post by ducke »

Good morning, everyone,
I take the liberty to come and ask for help from the community following a problem with ffmpeg that I can't solve on my own.

I need to recover a video track from a 1.mkv file, an audio track from another 2.mkv file and convert it to aac and a subtitle track from one of the 2 files (it's identical) and put it back in a .mkv file.

I manage to recover the video and the audio of their respective files, on the other hand as soon as I ask for the copy of the subtitle stream the audio file is corrupted, that is to say that I have some sound at the beginning then it cuts, then comes back for a few seconds later in the video, whereas if I don't integrate the sst track the audio works very well.

Here is my command:

Code: Select all

ffmpeg -i "S01E01.mkv" -i "OUT_S01E01.mkv" -map 1:v:0 -vcodec copy -map 0:a:0 -acodec aac -b:a 128k -map_metadata -1 -map 0:s:0  -scodec copy -f matroska "test.mkv"
If anyone has any idea what's wrong with the order...
Thank you in advance.


Edit: sorry for my bad translation, I use an online translator.

papomaqo
Posts: 1
Joined: Tue Mar 17, 2020 9:14 am

Re: Copy subtitle stream to an .mkv file

Post by papomaqo »

version?

ducke
Posts: 2
Joined: Sat Feb 15, 2020 11:06 am

Re: Copy subtitle stream to an .mkv file

Post by ducke »

ffmpeg version git-2020-02-13-6d37ca8 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 9.2.1 (GCC) 20200122

Post Reply