Suggestions for MKV files

Started by BogdanH, June 02, 2010, 01:24:54 PM

Previous topic - Next topic

BogdanH

Hi Phil,

It's the first time I've tried Exiftool (v8.21) on MKV file and noticed following (compared to other MKV tools):

1. Exiftool lists Chapter data inside "common" Matroska section. Usually, Chapters are listed/viewed as separate section (usually named Chapters or Menu) -which I find better.

2. ChapterTimeStart hour value is wrong in all cases except if it's complete value is zero. For example
RealValue Displayed
00:00:00  0s
00:20:00  333333:20:00
00:40:00  666666:40:00
01:00:00  1000000:00:00
01:20:00  1333333:30:00
..etc.
Maybe important: I don't set/use ChapterTimeEnd values when creating chapters for MKV.

3. For TrackType "Video":
-it would be very usefull, if some other important data would be shown.. at least:
e.g.Name = e.g.Value
FormatProfile=High@L4.1
FormatReFrames=4 frames
BitRate=8171 kbps
Duration=02:41:00 (must be here in case more video tracks are inside MKV)

I don't know, how to decode those values (seen in some other tools), but they are of great value.
Btw. I suggest displaying VideoFrameRate value on up to three decimal points (23,976 instead of 23,98) -it is important.

4. For TrackType"Audio":
-it would be usefull, if following important data would be shown:
Duration=02:41:00 (in case MKV contains several audio tracks)
BitRate=640 kbps
BitRate=Constant (because MP3 can have Variable)


5. Not that important, but anyway: maybe add DisplayAspectRatio tag value (as Composite from 1920x1080=16:9).

That's it. I wouldn't bother you with above, but since you decided to support MKV as well...  ;)

Greetings,
Bogdan

Phil Harvey

Hi Bogdan,

Quote from: BogdanH on June 02, 2010, 01:24:54 PM
1. Exiftool lists Chapter data inside "common" Matroska section. Usually, Chapters are listed/viewed as separate section (usually named Chapters or Menu) -which I find better.

I can do this.  Could you send me a sample MKV which contains chapters?  I don't have one of these for testing.

Quote
2. ChapterTimeStart hour value is wrong in all cases except if it's complete value is zero. For example
RealValue Displayed

Thanks.  I can fix this too if I have a sample for testing.

Quote3. For TrackType "Video":
-it would be very usefull, if some other important data would be shown.. at least:
e.g.Name = e.g.Value
FormatProfile=High@L4.1
FormatReFrames=4 frames
BitRate=8171 kbps
Duration=02:41:00 (must be here in case more video tracks are inside MKV)

I don't know, how to decode those values (seen in some other tools), but they are of great value.
Btw. I suggest displaying VideoFrameRate value on up to three decimal points (23,976 instead of 23,98) -it is important.

4. For TrackType"Audio":
-it would be usefull, if following important data would be shown:
Duration=02:41:00 (in case MKV contains several audio tracks)
BitRate=640 kbps
BitRate=Constant (because MP3 can have Variable)


I'll see what I can do. Currently I am not parsing the audio/video streams, and really don't want to do this because to add full support for these would require writing an awful lot of codecs myself. :(

Quote
5. Not that important, but anyway: maybe add DisplayAspectRatio tag value (as Composite from 1920x1080=16:9).

I'll think about this.

Thanks for your feedback.

- Phil

P.S.  Did you try the -U option?  It extracts all available Matroska information except for the audio/video streams themselves.
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

BogdanH

Hi,

I just sent you an mkv example (~25sec =~12Mb) containing chapters.

Of course I don't push on you to implement suggestions I've made. For me, Exiftool is photo tool -that's more than enough.

Greetings,
Bogdan

Phil Harvey

Thanks for the sample.  I appreciate the suggestions, they are very useful.

Here is the exiftool output after making a few improvements:

> exiftool -g1 Sample.mkv
---- ExifTool ----
ExifTool Version Number         : 8.22
---- System ----
File Name                       : Sample.mkv
Directory                       : .
File Size                       : 12 MB
File Modification Date/Time     : 2010:06:04 07:12:25-04:00
File Permissions                : rw-r--r--
---- File ----
File Type                       : MKV
MIME Type                       : video/x-matroska
---- Matroska ----
Doc Type                        : matroska
Doc Type Version                : 2
Doc Type Read Version           : 2
Timecode Scale                  : 1 ms
Muxing App                      : libebml v0.8.0 + libmatroska v0.9.0
Writing App                     : mkvmerge v3.3.0 ('Language') built on Mar 24 2010 14:59:24
Duration                        : 2:35:13
Date/Time Original              : 2010:06:03 18:48:09Z
---- Track1 ----
Track Number                    : 1
Track Type                      : Video
Track Used                      : Yes
Track Default                   : Yes
Track Forced                    : No
Track Timecode Scale            : 1
Video Codec ID                  : V_MPEG4/ISO/AVC
Codec Decode All                : Yes
Video Frame Rate                : 23.976
Track Language                  : eng
Track Name                      : Avatar video
Image Width                     : 1920
Image Height                    : 1080
Video Scan Type                 : Progressive
Display Width                   : 1920
Display Height                  : 1080
---- Track2 ----
Track Number                    : 2
Track Type                      : Audio
Track Used                      : Yes
Track Default                   : Yes
Track Forced                    : No
Track Timecode Scale            : 1
Audio Codec ID                  : A_AC3
Codec Decode All                : Yes
Default Duration                : 32 ms
Track Language                  : eng
Track Name                      : Avatar audio
Audio Sample Rate               : 48000
Audio Channels                  : 6
---- Track3 ----
Track Number                    : 3
Track Type                      : Subtitle
Track Used                      : Yes
Track Default                   : Yes
Track Forced                    : No
Track Timecode Scale            : 1
Codec ID                        : S_TEXT/UTF8
Codec Decode All                : Yes
Track Language                  : slv
Track Name                      : Avatar subtitles
---- Chapter1 ----
Chapter Time Start              : 0 s
Chapter String                  : Intro
Chapter Language                : eng
---- Chapter2 ----
Chapter Time Start              : 20:00
Chapter String                  : 0h 20min
Chapter Language                : eng
---- Chapter3 ----
Chapter Time Start              : 40:00
Chapter String                  : 0h 40min
Chapter Language                : eng
---- Chapter4 ----
Chapter Time Start              : 1:00:00
Chapter String                  : 1h 00min
Chapter Language                : eng
---- Chapter5 ----
Chapter Time Start              : 1:20:00
Chapter String                  : 1h 20min
Chapter Language                : eng
---- Chapter6 ----
Chapter Time Start              : 1:40:00
Chapter String                  : 1h 40min
Chapter Language                : eng
---- Chapter7 ----
Chapter Time Start              : 2:00:00
Chapter String                  : 2h 00min
Chapter Language                : eng
---- Chapter8 ----
Chapter Time Start              : 2:20:00
Chapter String                  : 2h 20min
Chapter Language                : eng
---- Composite ----
Base Name                       : Sample
File Extension                  : mkv
File Type Description           : Matroska Video
Image Size                      : 1920x1080


Here I have implemented your points number 1 and 2.  I didn't find any more useful details in the Matroska metadata and I don't want to parse the audio/video streams, so I couldn't do anything about points 3 or 4.   Also, I didn't implement point 5 because there are complications for calculating the aspect ratio of videos with non-square pixels.  I could probably do this for Matroska only, but if I do this I would want it to apply to all video formats.  And unfortunately calculating this reliably across all formats isn't easy.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

BogdanH

I find this "chapters" output much more readable (and accurate ;) ).

Otherwise I agree with you: at this point Exiftool shows general content of MKV (without going much into details), which should be enough for "info about" use.

Bogdan