Can anonye tell me a way to delete all subtiles except from a number of specified languages from a MKV with FFMPEG, preferrably in way that this could be done sequentially from mutltiple files ?
Asked
Active
Viewed 3,005 times
1 Answers
4
Use the -map
option. Example:
ffmpeg -i input.mkv -map 0 -map -0:s -map 0:s:m:language:fra -c copy output.mkv
-map 0
Select all streams from input 0 (which isinput.mkv
in this example).-map -0:s
Negative mapping that omits all subtitle streams from input 0.-map 0:s:m:language:fra
meansinput 0:subtitles:metadata:language:french
which selects all subtitles streams with French language metadata.-c copy
Enables stream copy mode to only re-mux and not re-encoding.
As for sequential usage the answer depends on your OS. See How do you convert an entire directory with ffmpeg? for many examples.

llogan
- 121,796
- 28
- 232
- 243