Skip to content
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

5.1? #8

Closed
zhuker opened this issue Dec 23, 2015 · 3 comments
Closed

5.1? #8

zhuker opened this issue Dec 23, 2015 · 3 comments

Comments

@zhuker
Copy link

zhuker commented Dec 23, 2015

i tried playing my 5.1 aac wrapped in mp4 container here http://audiocogs.org/codecs/aac/
did not work
is it a limitation of the player or decoder?

here is the link to the file
https://drive.google.com/file/d/0B14m-5S5eoNQdG5JT3ZwSzJRSjQ/view

@crackofdusk
Copy link
Member

I tried it and the number of channels is detected correctly by aurora. The error preventing playback is: Buffer was of incorrect sample length. It comes from the resampling code. I have tried to update that to the latest version (which comes from https://github.com/taisel/XAudioJS), but that broke playback completely. I suspect I'm misusing the new API.

devongovett added a commit that referenced this issue Dec 24, 2015
Sometimes there are multiple elements of the same type in the same frame of audio. We can't reuse the element objects in that case, since memory would be overwritten.
@devongovett
Copy link
Member

I have updated the resampler in aurora, and that error no longer occurs. Released in v0.4.8.

However, that was not the only problem. We were reusing element objects in aac.js to save on allocations. However, it seems it is possible to have multiple instances of the same element type within the same frame, as demonstrated by this file. So as of 650d665 we no longer reuse the objects. This fixes the decoding problem. Released in v0.1.2.

Unfortunately, some implementations of the web audio API (particularly in Chrome) doesn't seem to handle audio with more than 2 channels very well, so there is some stuttering sounds when playing the file still. It works better in Firefox though.

@zhuker
Copy link
Author

zhuker commented Dec 24, 2015

@devongovett thanks
this same file plays fine in chrome audio tag

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants