No Linux, você tem um programa de conversão de mídia universal chamado avconv
(alternativamente ffmpeg
). Na forma básica, é controlado por extensões, então
avconv -i input.mkv output.ogm
fará a conversão correta.
No entanto, para preservar todos os fluxos, você precisa usar a opção -map
. Deixe-me apenas citar o manual:
-map [-]input_file_id[:stream_specifier][,sync_file_id[:stream_specifier]] | [linklabel] (output)
Designate one or more input streams as a source for the output file. Each input stream is identified by the input file index input_file_id and
the input stream index input_stream_id within the input file. Both indices start at 0. If specified, sync_file_id:stream_specifier sets which
input stream is used as a presentation sync reference.
The first "-map" option on the command line specifies the source for output stream 0, the second "-map" option specifies the source for output
stream 1, etc.
A "-" character before the stream identifier creates a "negative" mapping. It disables matching streams from already created mappings.
An alternative [linklabel] form will map outputs from complex filter graphs (see the -filter_complex option) to the output file. linklabel
must correspond to a defined output link label in the graph.
For example, to map ALL streams from the first input file to output
avconv -i INPUT -map 0 output
For example, if you have two audio streams in the first input file, these streams are identified by "0:0" and "0:1". You can use "-map" to
select which streams to place in an output file. For example:
avconv -i INPUT -map 0:1 out.wav
will map the input stream in INPUT identified by "0:1" to the (single) output stream in out.wav.
For example, to select the stream with index 2 from input file a.mov (specified by the identifier "0:2"), and stream with index 6 from input
b.mov (specified by the identifier "1:6"), and copy them to the output file out.mov:
avconv -i a.mov -i b.mov -c copy -map 0:2 -map 1:6 out.mov
To select all video and the third audio stream from an input file:
avconv -i INPUT -map 0:v -map 0:a:2 OUTPUT
To map all the streams except the second audio, use negative mappings
avconv -i INPUT -map 0 -map -0:a:1 OUTPUT
Note that using this option disables the default mappings for this output file.
Então você precisará disso:
avconv -i nput.mkv -map 0:v -map 0:a output.ogm
E sim, você pode armazenar várias faixas e até vídeo e texto no arquivo OGG, porque é um contêiner de mídia universal.