exokitxr / exokit

Native VR/AR/XR engine for JavaScript 🦖
MIT License
995 stars 117 forks source link

OfflineAudioContext support #556

Open chrisnovello opened 6 years ago

chrisnovello commented 6 years ago

Went to try the megafun tone.js lib as a way to test WebAudio features and first thing I bumped into was

10-17 22:02:00.353 2044 10 I exokit : ReferenceError: OfflineAudioContext is not defined

Tough to wire up? Would try to offer help here myself but no C++ background and also just starting to reason in WebAudio api affordances

V hype for ongoing WebAudio support efforts, it open a lot! Thanks for all this !!!

avaer commented 6 years ago

OfflineAudioContext is just not exposed; as I understand it it's just an AudioContext (which is exposed), that doesn't render.

The bigger issue here is the callback management of AudioBuffers, which has outstanding bugs: https://github.com/webmixedreality/exokit/pull/287

However none of this is Magic Leap related; this code is agnostic to the platform. Updating the title accordingly.

avaer commented 5 years ago

When the AudioBuffer callbacks are correct, this issue could be as simple as exposing a non-hardware-backed AudioContext -- we already support multiple parallel graphs.