Length (duration) calculation for MP4 files

This may not be a new report, but I did a quick check and didn't find it so here goes:

I have an MP4 file where there's a discrepancy between the calculated length in MP3Tag and the length as reported by both VLC Media Player and the Windows Property Details tab, which leads me to believe it may be a problem in MP3Tag. MP3Tag reports the length as 3h57m. VLC Media Player and Properties report it as 4h17m. The file is 24 fps (instead of the more usual 30 or 29.97 fps) so I'm thinking that might the crux of the issue. I'm running the 316-x64 version.

perhaps this is something similar to mp3s with vbr:

If you can upload the file and send me a private link to download it, I can have a look and analyze the file. Otherwise it's nearly impossible to say something about it.

I was thinking the discrepancy (a word I chose carefully but unfortunately didn't use consistently) was due to the frame rate, but as you suggest it could very well be related to variable bit rate, as I have no idea what algorithm MP3tag uses or what factors the length/duration estimate is based on. I have only seen the discrepancy once, and if nobody else has noticed the discrepancy on MP4 files, it is IMO not worth Florian's time to pursue it any further, and I apologize for bringing it up.

Thanks for the reply – it’s a huge file and to be honest it’s not a big deal, I just thought you should be aware of it in case someone else comes up with the same problem. Mine could be a one-off and unless it’s a general problem it’s not worth messing with. Cheers!

OK, I have no other option as to move it to #bug-reports:no-bugs then. If you find a smaller files that shows a similar discrepancy, please let me know.

One last thing maybe: you could verify the integrity of the file using foobar2000 as outlined here:

1 Like