Log in

View Full Version : Matroska bitrates?


SteMa
6th June 2007, 10:19
I have several mkv files with 720p content in it, and mostly 2 audio tracks. How can I tell the bitrates of those contents. Mediainfo shows a bitrate, but I don't know if it contains the overhead (filesize/time [kbps]). I would like to know the bitrate for the video, and each audio tracks separately. Is that possible with some tool? I would like to know the exact value.

Best regards,
SteMa

buzzqw
6th June 2007, 11:16
avinaptic (use the search) could give more info on mkv file!

BHH

miztadux
6th June 2007, 17:10
AFAIK, avinaptic (at least the version i'm used to) doesn't give any info about the tracks bitrate... BUT it prints the encoding settings of x264 tracks which in turn CAN contain the bitrate specified at encode time (which is different from the real attained bitrate)

So avinaptic (which is very nice) can give you the *requested* bitrate of x264 tracks that were encoded in "bitrate mode"
(I don't think there will be a bitrate in x264 tracks encoded in CQ)

But you won't get the audio tracks bitrates...anyway you can always guess the bitrate of all audio tracks = bitrate given by MediaInfo (which is the whole file's bitrate) - bitrate found in x264 with avinaptic.

If you want the *exact* values I guess the best is to demux, but for constant bitrate audio files (most ac3, dts...) you can just extract a few secs and check the bitrate in mpc or else...

SteMa
6th June 2007, 17:38
isn't the bitrate the mediainfo gives is just the filesize divided by the length? In that case it has the overhead count into it. Sometimes I have 2 audio tracks, ac3, and they could be anything, even in 5.1ch mode: 384-448-640kbps. But I can change the language in bsplayer, and the ac3filter shows the current audio's bitrate, so that's checked! I need the video bitrate, I'll try that program. I searched a lot but didn't find anything useful yet.

foxyshadis
6th June 2007, 20:56
mkvverify -summary can give you per-track sizes/bitrates.

LeMoi
7th June 2007, 20:11
mkvverify -summary can give you per-track sizes/bitrates.

Indeed, excellent method

Tack
9th June 2007, 16:03
mkvverify -summary can give you per-track sizes/bitrates.I can't find the source code to mkvverify, so I'm not able to tell from this tool, but is the bitrate stored somewhere in the Matroska file as an EBML element (I'm not able to see that in the spec though), or does mkvverify poke into the stream itself to determine bitrate?

foxyshadis
9th June 2007, 18:34
It reads the entire file, using the track sizes and start/end timecodes to calculate bitrate, iirc. Sadly, no per-track size headers are stored anywhere, which would make analysis much simpler. ;_;

You can get the source by emailing Mr. Noé.

fsinapsi
16th June 2007, 13:10
AFAIK, avinaptic (at least the version i'm used to) doesn't give any info about the tracks bitrate...
this is a part of a report, before DRF analysis:

[ Video track ]

Codec ID: V_MS/VFW/FOURCC
Resolution: 640 x 360
Frame aspect ratio: 16:9 = 1.777777
Pixel aspect ratio: 1:1 = 1
Display aspect ratio: 16:9 = 1.777777
Framerate: 23.976000 fps

[ Audio track ]

Codec ID: A_MPEG/L3
Channels: 2
Sample rate: 48000 Hz


and this is the same part, after analysis:

[ Video track ]

Codec ID: V_MS/VFW/FOURCC
Resolution: 640 x 360
Frame aspect ratio: 16:9 = 1.777777
Pixel aspect ratio: 1:1 = 1
Display aspect ratio: 16:9 = 1.777777
Framerate: 23.976000 fps
Stream size: 180,222,645 bytes
Bitrate: 1017.877805 kbps
Qf: 0.184262

[ Audio track ]

Codec ID: A_MPEG/L3
Channels: 2
Sample rate: 48000 Hz
Stream size: 28,327,680 bytes
Bitrate: 159.991641 kbps

SteMa
7th July 2007, 14:29
Thanks for all the help guys! I can't believe that I can't see the size of a track in a matroska file, that way I could easily divide it by the length and get the bitrate.