I have some questions about mkclean... dont know if this the right location to ask, but since i've saw other questions about matroska, mkclean, metadata and similar i'll just ask...
Basically, its the question about the command line options and what they do. Sadly, i did not found any documentation on the website and the explanation on the command line is... short.
TL/DR
What do the command line switches --optimize, --optimize_nv, --no-opimize, --remux, --live and --timecodescale of the mkclean command line tool do? And what switches can 'safely' applied to existing files so they a) have good compatiblity with TVs or mobile devices over network shares and b) dont loose features for high level devices like computers.
Long Story
First, the command line arguments I think I understand:
--keep-cues keep the original Cues content and move it to the front
Similar to ffmpegs -movflags faststart for mp4 files which moves the meta/index data from the end of the file (its written there since the encoder only has full knowledge after encoding has completed) to the beginning of the file. Skipping this argument writes a newly calculated index to the beginning of the file ignoring the existing index. Source
--doctype <v> force the doctype version
1: 'matroska' v1
2: 'matroska' v2
3: 'matroska' v3
4: 'webm'
5: 'matroska' v1 with DivX extensions
6: 'matroska' v4
Think thats here to force compatibility to players that only support a specific version of the matroska file format. But it also seems to have direct impact on the optimize flag. Unconfirmed.
--unsafe don't output elements that are used for file recovery (saves more space)
Think thats self explaining. But did not know that matroska files do contain recovery data... What type of 'damage' can be recovered? Yeah, thats a different question.
Second, the command line arguments i dont understand and i am interested in
--timecodescale <v> force the global TimecodeScale to <v> (1000000 is a good value)
I have no idea what that means.
--optimize use all possible optimization for the output file
Now it gets exciting. Optimiziations. Probably what we are here for (besides the index at the beginning of the file). But what optimizations? Only thing I found that this removes matroska elements that are above the selected doctype (dont find the source for this :(). Say we use --doctype 2 this should remove all matroska document elements that are v3 or newer. Makes sense on one hand (forcing compatibility, but then it shouldn't be named optimization, right?) and doesnt make sense on the other hand since matroska file readers should ignore elements they don't understand so removing them will void them forever... If we see the next command line switch, this switch also applies video optimization... But which?
--optimize_nv use all possible optimization for the output file, except video tracks
This is more or less clear. It does the same as above but ignores video tracks. And yet we don't know what it does...
--no-optimize disable some optimization for the output file
Might just be poorly worded, but disables some optimizations for the file. Some optimizations... which are disabled, and which are not?
Third, the command line arguments i dont understand
--remux redo the Clusters layout
--live the output file resembles a live stream