MediaInfoLib: Wrong catching of sequence of files as a single media package

Trying to understand the different bitrate meaning, as bitRate_Nominal, bitRate_Maximum (that i found “anormally” hight on my ISMA sample file) and bitRate_Encoded.

When i read this log below, i just get totally confused about OverallBitRate and OverallBitRate_Maximum. How the last one could inferior to the first one ? and be that different ? I cannot understand their calculation from the videos and audios streams.

Any help welcome. Thank you for your understanding.

    General
    ID/String : 0 (0x0)
    Format : BDAV
    Format/Info : Blu-ray Video
    FileSize/String : 7.59 GiB
    Duration/String : 1mn 16s
    OverallBitRate_Mode/String : Variable
    OverallBitRate/String : 848 Mbps
    OverallBitRate_Maximum/String : 48.0 Mbps

    Video #1
    ID/String : 4113 (0x1011)
    MenuID/String : 1 (0x1)
    Format : AVC
    Format/Info : Advanced Video Codec
    Format_Profile : High@L4.1
    Format_Settings_CABAC/String : Yes
    Format_Settings_RefFrames/String : 4 frames
    Format_Settings_GOP : M=3, N=12
    CodecID : 27
    Duration/String : 1mn 16s
    BitRate_Mode/String : Constant
    BitRate_Nominal/String : 10.0 Mbps
    Width/String : 1 280 pixels
    Height/String : 720 pixels
    DisplayAspectRatio/String : 16:9
    FrameRate/String : 23.976 fps
    ColorSpace : YUV
    ChromaSubsampling : 4:2:0
    BitDepth/String : 8 bits
    ScanType/String : Progressive
    Bits-(Pixel*Frame) : 0.453
    colour_range : Limited
    colour_primaries : BT.709
    transfer_characteristics : BT.709
    matrix_coefficients : BT.709

    Video #2
    ID/String : 6912 (0x1B00)
    MenuID/String : 1 (0x1)
    Format : AVC
    Format/Info : Advanced Video Codec
    Format_Profile : High@L3.2
    Format_Settings_CABAC/String : Yes
    Format_Settings_RefFrames/String : 4 frames
    Format_Settings_GOP : M=3, N=12
    CodecID : 27
    Duration/String : 1mn 16s
    BitRate_Mode/String : Variable
    BitRate_Maximum/String : 7 992 Kbps
    Width/String : 720 pixels
    Height/String : 480 pixels
    DisplayAspectRatio/String : 16:9
    FrameRate/String : 23.976 fps
    Standard : NTSC
    ColorSpace : YUV
    ChromaSubsampling : 4:2:0
    BitDepth/String : 8 bits
    ScanType/String : Progressive
    colour_range : Limited
    colour_primaries : BT.601 NTSC
    transfer_characteristics : BT.601
    matrix_coefficients : BT.601

    Audio #1
    ID/String : 4352 (0x1100)
    MenuID/String : 1 (0x1)
    Format : DTS
    Format/Info : Digital Theater Systems
    Format_Settings_Mode : 16
    Format_Settings_Endianness : Big
    CodecID : 130
    Duration/String : 1mn 16s
    BitRate_Mode/String : Constant
    BitRate/String : 768 Kbps
    Channel(s)/String : 2 channels
    ChannelPositions : Front: L R
    SamplingRate/String : 48.0 KHz
    BitDepth/String : 16 bits
    Compression_Mode/String : Lossy
    StreamSize/String : 6.99 MiB (0%)

    Audio #2
    ID/String : 6656 (0x1A00)
    MenuID/String : 1 (0x1)
    Format : DTS
    Format/Info : Digital Theater Systems
    Format_Profile : Express
    Format_Settings_Mode : 16
    Format_Settings_Endianness : Big
    CodecID : 162
    Duration/String : 1mn 16s
    BitRate_Mode/String : Constant
    BitRate/String : 192 Kbps
    Channel(s)/String : 2 channels
    ChannelPositions : Front: L R
    SamplingRate/String : 48.0 KHz
    BitDepth/String : 16 bits
    Compression_Mode/String : Lossy
    StreamSize/String : 1.75 MiB (0%)

    Text #1
    ID/String : 4608 (0x1200)
    MenuID/String : 1 (0x1)
    Format : PGS
    CodecID : 144
    Duration/String : 1mn 10s
    Video_Delay/String : 1s 1ms

    Text #2
    ID/String : 4609 (0x1201)
    MenuID/String : 1 (0x1)
    Format : PGS
    CodecID : 144
    Duration/String : 1mn 10s
    Video_Delay/String : 1s 1ms

    Text #3
    ID/String : 4610 (0x1202)
    MenuID/String : 1 (0x1)
    Format : PGS
    CodecID : 144
    Duration/String : 1mn 10s
    Video_Delay/String : 1s 1ms

    Text #4
    ID/String : 4611 (0x1203)
    MenuID/String : 1 (0x1)
    Format : PGS
    CodecID : 144
    Duration/String : 1mn 10s
    Video_Delay/String : 1s 1ms

    Text #5
    ID/String : 4612 (0x1204)
    MenuID/String : 1 (0x1)
    Format : PGS
    CodecID : 144
    Duration/String : 1mn 10s
    Video_Delay/String : 1s 1ms

    Text #6
    ID/String : 4613 (0x1205)
    MenuID/String : 1 (0x1)
    Format : PGS
    CodecID : 144
    Duration/String : 1mn 10s
    Video_Delay/String : 1s 1ms

About this issue

  • Original URL
  • State: open
  • Created 7 years ago
  • Comments: 20 (12 by maintainers)

Most upvoted comments

It is a problem as it is not an expected behavior, but my sponsors (paying for it) have priority for the moment so I let the option enabled; when I have time (I don’t have it for the moment), I’ll see what I can do for catching only the real sequences of files.

I edited the ticket (title, labels) accordingly.

BitRate_Nominal: indicated (in the bitstream) average bitrate BitRate_Maximum: maximal instantaneous bitrate; with MP4 based files, it is per frame and may be not good, should be per GOP, I need to change that in order to avoid high values as you see. BitRate_Encoded: sometimes a stream is inside another one, e.g. audio and video are together in DV in MOV, and one can not be removed. BitRate is the bit rate of the audio in case it is demuxed from DV, BitRate_Encoded is 0 because it adds no bitrate to the file as it is already in the bitrate of the video part. This is quite complicated and the output of MediaInfo is definitely not perfect for showing all differences.

For audio, this is often CBR, and when it is VBR you can not know maximum bitrate without parsing the whole file, I got some TS files with AAC having low bitrate during 1 hour then during few seconds a very high bitrate, you can catch that only by parsing the whole file because there is no metadata for that. No luck… We plan to provide graph of instantaneous bitrate and maximum bitrate with full parsing (so it will be long on your side: the time to load the whole file from disk…), but no ETA for the moment.

Thanks! This is a good start, but still a bit light because you don’t have e.g. maximum supported H264 profile/level. So you have 2 issues:

  • MediaInfo may be wrong
  • User input is always with errors, not easy to handle.

side note: I don’t think the bitrate is the biggest difference to check, I suggest to focus on profile/level first, but this is subjective.

As we (the developers) don’t have access to most of the devices, we’re relying on user feedback.

Our common fate 😦.


I am interested at some point in the future to have something more automated about compatibility, this is long term. I’ll ping you and @Sami32 when I have something interesting to show for semi-automating such config file.


Back to this ticket: I reserve it for the issue about the sequence of files, which should be tweaked in order to avoid duration/bitrate info errors by default with Blurays.

I can’t find any among the 460 with a size of 7.59 GiB

OK, I think I see the source of the issue: there is a feature in MediaInfo which detects sequence of files (xxx000.mts, xxx001.mts…) and consider them as a single package because it is the case with a couple of my clients (and files coming from HLS and so on). as you tested the mts file directly and not the mpls file, and on a BDMV with lot of files, MediaInfo took it as a single package and computed duration as last time stamp of last file minus first timestamp of first file, which is wrong in your case as files ar independent. This is the reason duration so overall bitrate is wrong. With CLI: disable the feature " --File_TestContinuousFileNames=0" With GUI: not possible to disable the feature

So this is a bad side effect of a feature enabled by default, I need to fix that in order to avoid BDMV directories when I check sequence of files, but I can promise no ETA.

I just picked a .m2ts file at random from a set of bluray discs that turns out to have 460 .m2ts files. I had no idea that the file was “special” in any way so now I’m having a hard time finding it again. I removed the file path when I pasted it for “privacy reasons” 😭

I can’t find any among the 460 with a size of 7.59 GiB when I look at Windows explorer’s reported size. It should be added that I have a very low (0.7 Mbps) upload speed, so uploading 7.59 GiB would take approximately forever even if/when I find the file.

To make it even worse, I did this on my laptop, not my development computer (which I use most of the time). When I installed the MediaInfo GUI the first time (1.5 - 2 years ago) it had some malware bundled in the installer, which meant I had to find an even older version which had a “clean” installer. I’ve since downloaded the non-installer version on my development computer and overwritten the files of the installed version, but I haven’t done so on my laptop. That means this is done with a quite old version, 0.7.73.

I missed the part about OverallBitRate

OverallBitRate_Maximum and OverallBitRate are computed differently, looks like it is a bug on OverallBitRate with this file (bug looks like to come from duration detection). I can not say more or debug without the file.