Mediainfo to get the actual bitrate of video and audio to be placed on the stamp detail

All about the program
uhnam
Posts: 1
Joined: 26 Aug 2024, 22:49

26 Aug 2024, 23:25

Hi, All

Straight to the point. The bit rate displayed in the Video: section in the result thumbnail is the total bit rate, which is a combination of video and audio bitrates that if checked using ffmpeg / ffprobe, is at the top of the output, precisely in the duration line: ... (bitrate: 1409 kb/s)

Code: Select all

$ ffprobe -hide_banner vsshort-aac.mkv

Input #0, matroska,webm, from 'vsshort-aac.mkv':
  Metadata:
    encoder         : libebml v1.4.5 + libmatroska v1.7.1
    creation_time   : 2024-08-26T20:03:38.000000Z
  Duration: 00:01:09.78, start: 0.000000, bitrate: 1409 kb/s
  Stream #0:0: Video: msmpeg4v3 (msmpeg4) (DIV3 / 0x33564944), yuv420p, 640x352, SAR 1:1 DAR 20:11, 23.98 fps, 23.98 tbr, 1k tbn (default)
      Metadata:
        BPS             : 1278655
        DURATION        : 00:01:09.778000000
        NUMBER_OF_FRAMES: 1673
        NUMBER_OF_BYTES : 11152757
        _STATISTICS_WRITING_APP: mkvmerge v86.0 ('Winter') 64-bit
        _STATISTICS_WRITING_DATE_UTC: 2024-08-26 20:03:38
        _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
  Stream #0:1: Audio: aac (LC), 48000 Hz, stereo, fltp (default)
      Metadata:
        BPS             : 127874
        DURATION        : 00:01:09.780000000
        NUMBER_OF_FRAMES: 3271
        NUMBER_OF_BYTES : 1115389
        _STATISTICS_WRITING_APP: mkvmerge v86.0 ('Winter') 64-bit
        _STATISTICS_WRITING_DATE_UTC: 2024-08-26 20:03:38
        _STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
While the actual video bitrate is: 1278655 bps (1279 kb/s), and audio is 127874 bps (128 kb/s). Those details are also displayed in mediainfo.

The problem is that I did not find an option to display the actual bitrate of both.So, are you willing to implement the use of mediainfo to retrieve these details and then put them on the stamp detail?

Thank you and kind regards,
Uhnam
User avatar
admin
Site Admin
Posts: 1442
Joined: 03 Jun 2014, 22:14

27 Aug 2024, 18:13

Hello,

I can enhance the video bitrate detection for MKV specifically.

And you are right, it is important, especially for MKV.
User avatar
admin
Site Admin
Posts: 1442
Joined: 03 Jun 2014, 22:14

27 Aug 2024, 20:30

Implemented in VTM 26.0.0.2
sergeant
Posts: 4
Joined: 14 Oct 2024, 15:37

14 Oct 2024, 17:01

admin wrote: 27 Aug 2024, 18:13 Hello,

I can enhance the video bitrate detection for MKV specifically.

And you are right, it is important, especially for MKV.
admin wrote: 27 Aug 2024, 20:30 Implemented in VTM 26.0.0.2
Hello,

For me, there's still something not quite right in the output produced by VTM 26.0.0.2.
  1. There's empty space if the bitrate is in the thousands: 22 114 kb/s, and is in MB & bytes.
  2. Mb/s bitrate in mediainfo: 22.1 Mb/s, displayed by VTM in thousands unit format: 22 114 kb/s.
Both of them are only in the video & size section: https://i.imgur.com/3Ruhh1r.png. So, are you willing to fix them?. Thank you a lot.

Cheers,
Sergeant
Last edited by sergeant on 14 Oct 2024, 17:12, edited 1 time in total.
User avatar
admin
Site Admin
Posts: 1442
Joined: 03 Jun 2014, 22:14

23 Oct 2024, 20:48

sergeant wrote: 14 Oct 2024, 17:01 [*]There's empty space if the bitrate is in the thousands: 22 114 kb/s, and is in MB & bytes.
Hello,

Options (F2) -> Miscellaneous
Separate_Thousands.png
Separate_Thousands.png (7.55 KiB) Viewed 2617 times
sergeant
Posts: 4
Joined: 14 Oct 2024, 15:37

24 Dec 2024, 00:58

admin wrote: 23 Oct 2024, 20:48Hello,

Options (F2) -> Miscellaneous
Hello,

It is only work if the GB checkbox was checked. So man, would you like to make it work for MB and B?. Thank you a lot.

Cheers,
Sergeant
User avatar
admin
Site Admin
Posts: 1442
Joined: 03 Jun 2014, 22:14

24 Dec 2024, 16:21

sergeant wrote: 24 Dec 2024, 00:58It is only work if the GB checkbox was checked. So man, would you like to make it work for MB and B?. Thank you a lot.
Just rechecked, it already works for MB and B.
sergeant
Posts: 4
Joined: 14 Oct 2024, 15:37

25 Dec 2024, 14:56

admin wrote: 24 Dec 2024, 16:21Just rechecked, it already works for MB and B.
Hello,

I am using the latest version: VTM 26.0.0.2, and have done what you suggested, but it still fails. Even worse, it doesn't work.

More details with proof:
  1. Options (F2) -> Miscellaneous, the default settings for all: https://www.imagebam.com/view/MEYG82A.
  2. For GB sized files.
    1. Sample #1, the "Technical Details" settings are here, and the results are here.
    2. Sample #2, the "Technical Details" settings are here, and the results are here.
  3. For MB sized files, the "Technical Details" settings are here, and the results are here.
As you can see, what I mean is that comma can only work in bytes only when MB checkbox was unchecked, and it only works on sample #2 for GB sized file as shown in the pic.

Moreover, exactly in the File Size section: there's an annoying unused blank space between the words GB & MB and the /, also before the words bytes, as shown in the pic, too.

So again man, would you like to make it work?. Thank you a lot.

Cheers,
Sergeant
User avatar
admin
Site Admin
Posts: 1442
Joined: 03 Jun 2014, 22:14

25 Dec 2024, 18:58

Ok, thank you for the details.
I didn't get your initial question. Now it is clear. I will fix the issues.
The current implementation is like the size is bytes is always separated by something. Otherwise it will be hard to read.
Do you still want to have bytes without any separator?
The second variant is much clearer from my point of view:
169234152 bytes
169 234 152 bytes
sergeant
Posts: 4
Joined: 14 Oct 2024, 15:37

25 Dec 2024, 23:29

admin wrote: 25 Dec 2024, 18:58...to have bytes without any separator: 169234152 bytes
Hello,

Aha, you're absolutely right, man. Bytes without any separator is will be so easier to program. It's also very nice, and is much better from my point of view, too :D. Thank you a lot.

Cheers,
Sergeant
Post Reply