Re: [Bug 17793] New: AudioNode.disconnect() needs to be able to disconnect only one connection

> Recommended solution:
> - there should be a way to remove a single connection (by supplying the
> destination node to be disconnected, since there can only be one
connection to
> a given destination node [tested]).
>
> E.g.: the IDL for disconnect should read:
>
>         void disconnect(in [Optional] AudioNode destination, in [Optional]
> unsigned long output = 0)
>             raises(DOMException);
>
> this lets us keep most compatibility - node.disconnect() will still
remove all
> connections.

I'm confused now.

" node.disconnect() will still remove all connections."

Is this the case? That would help me a lot. I only now see in the draft
that the in-parameter is optional, so: does not supplying any params to the
disconnect method remove the whole node with every connection to and from
it like that uote says? If so, that is not mentioned in the explanation in
the draft, it's even incorrect:

Disconnects an AudioNode's output.

The output parameter is an index describing which output of the AudioNode
to disconnect. An out-of-bound value throws an exception.
Then: "(by supplying the destination node to be disconnected, since there
can only be one connection to a given destination node [tested])."

I was already wondering what would happen if i tried to connect the same
output and same input twice (i guessed it would fail...does it?) but this
implies even more. Nodes can have multiple inputs and outputs, and by
reading this sentence i understand i wouldn't be able to connect for
example one output to two different inputs on another node. That can't be
right, i think you should supply a node *with* the index of the input,
instead of just the node.

Peter

Received on Tuesday, 17 July 2012 18:51:42 UTC