This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
I may be wrong, but it seems to me that currently the JavaScriptNode has no way of filling the buffers asynchronously. I suggest we adopt the way that Robert's proposal did the callbacks, having a write method on the event. Allowing asynchronous writes makes sense in an environment like JS where most of the external operations are asynchronous. Also, for example if we define a DSP library that supports things such as convolution, it would be ideal for it to provide asynchronous versions of the calls as well, to make it more natural to the async flow of JS programs, not to mention that you could do concurrent overlap-add things. So for example (very simplified): var l = 2048 customNode.onaudioprocess = function (e) { var buffer = new Float32Array(l) oscillator.fillBufferAsync(buffer, function () { e.writeAudio(buffer) }) } This would also allow one to write data ahead of time.
I think we effectively already have an async write() in AudioBufferSourceNode.start()
(In reply to comment #1) > I think we effectively already have an async write() in > AudioBufferSourceNode.start() That's not suitable for continuous asynchronously generated audio, but this feature is actually probably better off as custom JS buffer handling. Closing.
Seeing no objection to the resolution as invalid in over 2 weeks, closing.