Re: Behavior of source nodes on connect/disconnect

On Sep 13, 2013, at 4:16 PM, Robert O'Callahan <robert@ocallahan.org> wrote:

> On Fri, Sep 13, 2013 at 1:50 PM, Jer Noble <jer.noble@apple.com> wrote:
> Of course, HTMLMediaElements must pause when they are removed from the DOM.  So in the general case, disconnecting a playing media element and throwing away all references to it will allow it to be GCd.
> 
> But you can call play() on a media element after removing it from the DOM.
> 
> If we were to follow the media element model in Web Audio, we would introduce per-node pause() and resume() APIs and specify that when you disconnect the last output of a node, there is an implicit pause() call.

I’d actually be fine with that.

One further hypothetical: should “pause” and “play” traverse down the graph?  I.e., if you “pause” a ConvolutionNode, would the AudioBufferSourceNode feeding it pause as well.

-Jer

Received on Friday, 13 September 2013 23:23:47 UTC