add MediaStreamAudioSourceNode
authorcrogers
Tue, 26 Jun 2012 15:56:31 -0700
changeset 90 a34e581ce43d
parent 89 563ce3b94a68
child 91 1079a18d951e
add MediaStreamAudioSourceNode
webaudio/specification.html
--- a/webaudio/specification.html	Tue Jun 26 21:35:01 2012 +0300
+++ b/webaudio/specification.html	Tue Jun 26 15:56:31 2012 -0700
@@ -287,6 +287,8 @@
       </li>
       <li><a href="#WaveTable">4.24. The WaveTable Interface</a> 
       </li>
+      <li><a href="#MediaStreamAudioSourceNode">4.25. The
+        MediaStreamAudioSourceNode Interface</a></li>
     </ul>
   <li><a href="#AudioElementIntegration">5. Integration with the
     <code>audio</code> and <code>video</code> elements</a></li>
@@ -727,6 +729,9 @@
             MediaElementAudioSourceNode createMediaElementSource(in HTMLMediaElement mediaElement)
                 raises(DOMException);
 
+            MediaStreamAudioSourceNode createMediaStreamSource(in MediaStream mediaStream)
+                raises(DOMException);
+
             JavaScriptAudioNode createJavaScriptNode(in unsigned long bufferSize,
                                                      in [Optional] unsigned long numberOfInputChannels = 2,
                                                      in [Optional] unsigned long numberOfOutputChannels = 2)
@@ -868,6 +873,15 @@
     </dd>
 </dl>
 <dl>
+  <dt id="dfn-createMediaStreamSource">The <code>createMediaStreamSource</code>
+  method</dt>
+    <dd><p>Creates a <a
+      href="#MediaStreamAudioSourceNode-section"><code>MediaStreamAudioSourceNode</code></a> given a MediaStream.
+      As a consequence of calling this method, audio playback from the MediaStream will be re-routed
+      into the processing graph of the AudioContext.</p>
+    </dd>
+</dl>
+<dl>
   <dt id="dfn-createJavaScriptNode">The <code>createJavaScriptNode</code>
   method</dt>
     <dd><p>Creates a <a
@@ -1904,8 +1918,7 @@
 Interface</h2>
 
 <p>This interface represents an audio source from an <code>audio</code> or
-<code>video</code> element. The element's <code>audioSource</code> attribute
-implements this. </p>
+<code>video</code> element. </p>
 <pre>    numberOfInputs  : 0
     numberOfOutputs : 1
     </pre>
@@ -3201,6 +3214,34 @@
 </div>
 </div>
 
+<div id="MediaStreamAudioSourceNode-section" class="section">
+<h2 id="MediaStreamAudioSourceNode">4.25. The MediaStreamAudioSourceNode
+Interface</h2>
+
+<p>This interface represents an audio source from a <code>MediaStream</code>.
+The first <code>AudioMediaStreamTrack</code> from the <code>MediaStream</code> will be
+used as a source of audio.</p>
+<pre>    numberOfInputs  : 0
+    numberOfOutputs : 1
+    </pre>
+
+<div class="block">
+
+<div class="blockTitleDiv">
+<span class="blockTitle">IDL</span></div>
+
+<div class="blockContent">
+<pre class="code"><code class="idl-code"> 
+
+    interface <dfn id="dfn-MediaStreamAudioSourceNode">MediaStreamAudioSourceNode</dfn> : AudioSourceNode {
+
+    }
+    </code></pre>
+</div>
+</div>
+</div>
+
+
 <div id="AudioElementIntegration-section" class="section">
 <h2 id="AudioElementIntegration">5. Integration with the <code>audio</code> and
 <code>video</code> elements</h2>