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

Added support for passing audio data as an ArrayBuffer #1647

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

andrewleek-droplab
Copy link

Issue/Feature

While working on a project we encountered the need to preload our audio assets with a custom loader. While it appeared that we could preload the audio assets and then pass them in as a base64 data URI, we ran into similar issues as referenced here: #1257

Related Issues

#1257

Solution

Our solution was to add an additional parameter called 'arraybuffer', which if set to an ArrayBuffer, would be decoded directly.

Reproduction/Testing

To test you simply need to pass in an ArrayBuffer from a loaded audio file.
*Note: you still need to pass in a url to src so that the audio buffer can be cached.

Breaking Changes

N/A

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

Successfully merging this pull request may close these issues.

None yet

3 participants