Open Sami32 opened 8 years ago
I don't know if it will acceptable or even follow the MediaInfo "convention", but i find an easyway to woraround that.
After having saw that renderers use some approximation algorithm for the duration, certainly the same as WMP, that are not accurate at all.
I then played with FFmpeg and discovered that -bsf:a aac_adtstoasc
filter will give me an immediate and accurate result: of course as M4A ;)
So i wondered if MediaInfo could use a similar filter for such case ?
I guess that you already knew about that, but as i was happy to find a way to solve my duration issue, and would like share it, in case that it can be useful to someone else as well.
So i wondered if MediaInfo could use a similar filter for such case ?
Are you sure FFmpeg does not parse the whole file? pure AAC files are usually small so if you test on a single file you may miss the fact the whole file is parsed. Parsing the whole file and getting the duration is also possible, but it would not be by default (in case someone parses thousands of files, it would be too slow).
Sure...no :flushed: As it was too fast, i thought that it was, but you could be right. And yes, i'm thinking about thousand of files been parsed as well, so that's interest me, as some users have huge libraries of 20.000 files, far biggest than my little test library.
How can i make sure FFmpeg filter do not parse the file ? I admit that checking at the FFmpeg code could be incertain for me, so perhaps try create a huge ADTS(AAC) file ?
Sniff...you are right.
It taken 7.6 s for a 220 MB AAC-LC (ADTS) file (1H30mn), so it's really parsed.
EDIT: Thank you for the idea of impleming it as an option :+1: as i should have missed that it was parsed and that some delay was added to users libraries scanning.
Hello,
Do you plane to implement this ?
I just discover that the duration was not displayed with this kind of AAC files, so my open source media server that use your very useful program don't as well.
I search on Internet and find this explanation :
Thank you for your amazing work :-D Regards