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

Unable to stream audio by fetching partial content of the audio #1245

Closed
logesh2496 opened this issue May 6, 2024 · 1 comment
Closed

Unable to stream audio by fetching partial content of the audio #1245

logesh2496 opened this issue May 6, 2024 · 1 comment

Comments

@logesh2496
Copy link

Describe the bug

I have been trying to set initial Range in the header and an auto fetch property to stream audio data instead of downloading the whole file from the provided url.

To Reproduce

Try to setup Range headers in the Tone.Player method.

Expected behavior
Would be great to have a method to auto fetch the bytes range as per the configurations

What I've tried
I have been trying to handle it all outside by fetching the audio and setting the buffer of the tone.player

@tambien
Copy link
Contributor

tambien commented May 16, 2024

The way that the Web Audio API converts audio files into AudioBuffers (decodeAudioData), it's not currently possible to stream. decodeAudioData requires the entire buffer be available. I'm going to close this issue for now, if this changes or new approaches come to light, we can reopen.

@tambien tambien closed this as completed May 16, 2024
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

2 participants