New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for aac
format
#208
Changes from 2 commits
a183a14
3950249
2b4af51
16fa1cb
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -443,7 +443,7 @@ const fileType = input => { | |
check([0xFF, 0xF0], {offset: start, mask: [0xFF, 0xFC]}) // MPEG 4 layer 0 using ADTS | ||
) { | ||
return { | ||
ext: 'mp4', | ||
ext: 'aac', | ||
mime: 'audio/mpeg' | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Media type should probably be There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I think you are right: (ref)
|
||
}; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AAAAAAAA AAAABCCD
2nd byte check should be
0b11110000
(0xF0
) with mask0b11111110
(0xFE
) foraac
then(and remaining options caught separately).There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
also, shouldn't mpeg2 be caught too?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There actually already is an ADTS/MPEG-2/ACC test file, originating from PR #136. Currently with
.mp2
extension, it looks like to reverse engineered the extension based on the MPEG version.Okay, lets assume this is ext.
.acc
mimeaudio/acc
candidate as well.