Mkvmerge (1) requires a video or an audio track to be present in order to be able to determine when a new file is appended. If one or more video tracks are muxed the first one is used. Otherwise the first audio track is used. 'interval: time-spec ' - This mode creates. Windows users will have to download the runtime DLLs as well as the mkvtoolnix binaries. Linux/Unix users will probably download the sources and compile mkvtoolnix themselves. Scope of this guide. This guide only focuses on the GUI part of these tools. All command line options are explained in detail in mkvmerge's man page/HTML page. For an in-depth discussion about how all tools in the MKVToolNix suite handle character set conversions, input/output encoding, command line encoding and console encoding please see the identically-named section in the mkvmerge(1) man page. This program takes the input from several media files and joins their streams (all of them or just a selection) into a Matroska(TM) file; seethe Matroska(TM) website. ImportantThe order of command line options is important. Please read the section 'Option order' if you're new to the program. Global options:-v, -verbose 1. Increase verbosity. Suppress status output.o, -output file-name 1. Write to the fi.

Let's assume you have a file called MyMovie.avi and the audio track in aseparate file, e.g. MyMovie.wav. First you want to encode the audio toOGG:

$ oggenc -q4 -oMyMovie.ogg MyMovie.wav

After a couple of minutes you can join video and audio:

$ mkvmerge -o MyMovie-with-sound.mkv MyMovie.avi MyMovie.ogg

If your AVI already contains an audio track then it will be copied as well(if mkvmerge supports the audio format). To avoid that simply do

$ mkvmerge -o MyMovie-with-sound.mkv -A MyMovie.avi MyMovie.ogg

After some minutes of consideration you rip another audio track, e.g.the director's comments or another language to MyMovie-add-audio.wav.Encode it again and join it up with the other file:

$ oggenc -q4 -oMyMovie-add-audio.ogg MyMovie-add-audio.wav
$ mkvmerge -o MM-complete.mkv MyMovie-with-sound.mkv MyMovie-add-audio.ogg

The same result can be achieved with

$ mkvmerge -o MM-complete.mkv -A MyMovie.avi MyMovie.ogg
MyMovie-add-audio.ogg

Now fire up mplayer and enjoy. If you have multiple audio tracks (or evenvideo tracks) then you can tell mplayer which track to play with the'-vid' and '-aid' parameters. These are 0-based and do notdistinguish between video and audio.

If you need an audio track synchronized you can do that easily. First findout which track ID the Vorbis track has with

$ mkvmerge --identify outofsync.ogg

Man mkvmerge

Now you can use that ID in the following command line:

$ mkvmerge -o goodsync.mkv -A source.avi -y 12345:200 outofsync.ogg

This would add 200ms of silence at the beginning of the audio track with theID 12345 taken from outofsync.ogg.

Some movies start synced correctly but slowly drift out of sync. For thesekind of movies you can specify a delay factor that is applied to alltimestamps - no data is added or removed. So if you make that factor toobig or too small you'll get bad results. An example is that an episodeI transcoded was 0.2 seconds out of sync at the end of the movie whichwas 77340 frames long. At 29.97fps 0.2 seconds correspond to approx. 6frames. So I did

$ mkvmerge -o goodsync.mkv -y 23456:0,77346/77340 outofsync.mkv

The result was fine.

The sync options can also be used for subtitles in the same manner.

For text subtitles you can either use some Windows software (likeSubRipper) or the subrip package found in transcode(1)'ssources (in contrib/subrip). The general process is:

1.
extract a raw subtitle stream from the source:
$ tccat -i /path/to/copied/dvd/ -T 1 -L |
tcextract -x ps1 -t vob -a 0x20 |
subtitle2pgm -o mymovie
2.
convert the resulting PGM images to text with gocr:
$ pgm2txt mymovie
3.
spell-check the resulting text files:
$ ispell -d american *txt
4.
convert the text files to a SRT file:
$ srttool -s -w -i mymovie.srtx -o mymovie.srt

The resulting file can be used as another input file for mkvmerge:

$ mkvmerge -o mymovie.mkv mymovie.avi mymovie.srt

If you want to specify the language for a given track then this is easilydone. First find out the ISO639-2 code for your language. mkvmergecan list all of those codes for you:

$ mkvmerge --list-languages

Search the list for the languages you need. Let's assume you have put twoaudio tracks into a Matroska file and want to set their language codes andthat their track IDs are 2 and 3. This can be done with

$ mkvmerge -o with-lang-codes.mkv --language 2:ger --language 3:dutwithout-lang-codes.mkv

As you can see you can use the --language switch multiple times.

Maybe you'd also like to have the player use the Dutch language as the defaultlanguage. You also have extra subtitles, e.g. in English and French, and wantto have the player display the French ones by default. This can be done with

$ mkvmerge -o with-lang-codes.mkv --language 2:ger --language 3:dut--default-track 3 without-lang-codes.mkv --language 0:eng english.srt--default-track 0 --language 0:fre french.srt

If you do not see the language or default track flags that you've specifiedin mkvinfo's output then please read the section about DEFAULTVALUES.

Description

This program analyses an existing Matroska(TM) file and modifies some of its properties. Then it writes those modifications to the existing file. Among the properties that can be changed are the segment information elements (e.g. the title) and the track headers (e.g. the language code, 'default track' flag or the name).

See full list on priede.bf.lu.lv

Options:

-l, --list-property-names

Lists all known and editable property names, their type (string, integer, boolean etc) and a short description. The program exits afterwards. Therefore the source-filename parameter does not have to be supplied.

-p, --parse-modemode

Sets the parse mode. The parameter 'mode' can either be 'fast' (which is also the default) or 'full'. The 'fast' mode does not parse the whole file but uses the meta seek elements for locating the required elements of a source file. In 99% of all cases this is enough. But for files that do not contain meta seek elements or which are damaged the user might have to set the 'full' parse mode. A full scan of a file can take a couple of minutes while a fast scan only takes seconds.

Actions that deal with track and segment info properties:

-e, --editselector

Sets the Matroska(TM) file section (segment information or a certain track's headers) that all following add, set and delete actions operate on. This option can be used multiple times in order to make modifications to more than one element.

By default mkvpropedit(1) will edit the segment information section.

See the section about edit selectors for a full description of the syntax.

-a, --addname=value

Adds a property name with the value value. The property will be added even if such a property exists already. Note that most properties are unique and cannot occur more than once.

-s, --setname=value

Sets all occurrences of the property name to the value value. If no such property exists then it will be added.

-d, --deletename

Deletes all occurrences of the property name. Note that some properties are required and cannot be deleted.

Actions that deal with tags and chapters:

-t, --tagsselector:filename

Add or replace tags in the file with the ones from filename or remove them if filename is empty. mkvpropedit(1) reads the same XML tag format that mkvmerge(1) reads as well.

The selector must be one of the words all, global or track. For all mkvpropedit(1) will replace or remove all tags in a file. With global only global tags will be replaced or removed.

With track mkvpropedit(1) will replace tags for a specific track. Additionally the tags read from filename will be assigned to the same track. The track is specified in the same way edit selectors are specified (see below), e.g. --tags track:a1:new-audio-tags.xml.

--add-track-statistics-tags

The Chapter Editor

Calculates statistics for all tracks in a file and adds new statistics tags for them. If the file already contains such tags then they'll be updated.

--delete-track-statistics-tags

Deletes all existing track statistics tags from a file. If the file doesn't contain track statistics tags then it won't be modified.

-c, --chaptersfilename

Add or replace chapters in the file with the ones from filename or remove them if filename is empty. mkvpropedit(1) reads the same XML and simple chapter formats that mkvmerge(1) reads as well.

Actions for handling attachments:

--add-attachmentfilename

Adds a new attachment from filename.

If the option --attachment-name has been used prior to this option then its value is used as the new attachment's name. Otherwise it is derived from filename.

If the option --attachment-mime-type has been used prior to this option then its value is used as the new attachment's MIME type. Otherwise it is auto-detected from the content of filename.

If the option --attachment-description has been used prior to this option then its value is used as the new attachment's description. Otherwise no description will be set.

If the option --attachment-uid has been used prior to this option then its value is used as the new attachment's UID. Otherwise a random UID will be generated automatically.

--replace-attachmentselector:filename

Replaces one or more attachments that match selector with the file filename. If more than one existing attachment matches selector then all of their contents will be replaced by the content of filename.

The selector can have one of four forms. They're explained below in the section attachment selectors.

If the option --attachment-name has been used prior to this option then its value is set as the new name for each modified attachment. Otherwise the names aren't changed.

If the option --attachment-mime-type has been used prior to this option then its value is set as the new MIME type for each modified attachment. Otherwise the MIME types aren't changed.

If the option --attachment-description has been used prior to this option then its value is set as the new description for each modified attachment. Otherwise the descriptions aren't changed.

If the option --attachment-uid has been used prior to this option then its value is set as the new UID for each modified attachment. Otherwise the UIDs aren't changed.

Man Mkvmerge
--update-attachmentselector

Sets the properties of one or more attachments that match selector. If more than one existing attachment matches selector then all of their properties will be updated.

The selector can have one of four forms. They're explained below in the section attachment selectors.

If the option --attachment-name has been used prior to this option then its value is set as the new name for each modified attachment. Otherwise the names aren't changed.

If the option --attachment-mime-type has been used prior to this option then its value is set as the new MIME type for each modified attachment. Otherwise the MIME types aren't changed.

If the option --attachment-description has been used prior to this option then its value is set as the new description for each modified attachment. Otherwise the descriptions aren't changed.

If the option --attachment-uid has been used prior to this option then its value is set as the new UID for each modified attachment. Otherwise the UIDs aren't changed.

--delete-attachmentselector

Deletes one or more attachments that match selector.

The selector can have one of four forms. They're explained below in the section attachment selectors.

Options for attachment actions:

--attachment-namename

Sets the name to use for the following --add-attachment or --replace-attachment operation.

--attachment-mime-typemime-type

Sets the MIME type to use for the following --add-attachment or --replace-attachment operation.

--attachment-descriptiondescription

Sets the description to use for the following --add-attachment or --replace-attachment operation.

Other options:

--disable-language-ietf

Normally when the user requests changes to the 'language' track header property, mkvpropedit(1) will apply the same change to the new LanguageIETF track header element in addition to the legacy Language element. If this option is used, the change is only applied to the legacy Language element.

See Full List On Priede.bf.lu.lv

This option does not affect changes requested via the 'language-ietf' track header property.

--command-line-charsetcharacter-set

Sets the character set to convert strings given on the command line from. It defaults to the character set given by system's current locale.

--output-charsetcharacter-set

Sets the character set to which strings are converted that are to be output. It defaults to the character set given by system's current locale.

-r, --redirect-outputfile-name

Writes all messages to the file file-name instead of to the console. While this can be done easily with output redirection there are cases in which this option is needed: when the terminal reinterprets the output before writing it to a file. The character set set with --output-charset is honored.

--ui-languagecode

Forces the translations for the language code to be used (e.g. 'de_DE' for the German translations). Entering 'list' as the code will cause the program to output a list of available translations.

--abort-on-warnings

Tells the program to abort after the first warning is emitted. The program's exit code will be 1.

--debugtopic

Turn on debugging for a specific feature. This option is only useful for developers.

--engagefeature

Turn on experimental features. A list of available features can be requested with mkvpropedit --engage list. These features are not meant to be used in normal situations.

--gui-mode

Turns on GUI mode. In this mode specially-formatted lines may be output that can tell a controlling GUI what's happening. These messages follow the format '#GUI#message'. The message may be followed by key/value pairs as in '#GUI#message#key1=value1#key2=value2...'. Neither the messages nor the keys are ever translated and always output in English.

-v, --verbose

Be verbose and show all the important Matroska(TM) elements as they're read.

-h, --help

Show usage information and exit.

-V, --version

Show version information and exit.

@options-file.json

Reads additional command line arguments from the file options-file. For a full explanation on the supported formats for such files see the section called 'Option files' in the mkvmerge(1) man page.