- From: CVS User dburnett <cvsmail@w3.org>
- Date: Sat, 24 Aug 2013 14:10:53 +0000
- To: public-dap-commits@w3.org
Update of /sources/public/2011/webrtc/editor In directory roscoe:/tmp/cvs-serv5352 Modified Files: getusermedia.html getusermedia.js Log Message: Added 20130824 archived version. --- /sources/public/2011/webrtc/editor/getusermedia.html 2013/07/04 13:38:43 1.21 +++ /sources/public/2011/webrtc/editor/getusermedia.html 2013/08/24 14:10:53 1.22 @@ -733,8 +733,12 @@ rendering media from the source. A muted track will however, regardless of the enabled state, render silence and blackness. A disabled track is logically equivalent to a muted track, from a consumer point of view. - A newly created <code><a>MediaStreamTrack</a></code> object is always - enabled unless stated otherwise.</p> + </p> + + <p>For a newly created <code><a>MediaStreamTrack</a></code> object, the + following applies. The track is always enabled unless stated otherwise + (for examlpe when cloned) and the muted state reflects the state of the + source at the time the track is created.</p> <p>A <code><a>MediaStreamTrack</a></code> object is said to <em>end</em> when the source of the track is disconnected or exhausted.</p> @@ -1075,8 +1079,9 @@ <li> <p>Let <var>trackClone</var> inherit this track's underlying source, <code> - <a href="#dom-mediastreamtrack-kind">kind</a></code> and <code> - <a href="#dom-mediastreamtrack-label">label</a></code> + <a href="#dom-mediastreamtrack-kind">kind</a></code>, <code> + <a href="#dom-mediastreamtrack-label">label</a></code> and + <a href="#dom-mediastreamtrack-enabled">enabled</a></code> attributes.</p> </li> @@ -1863,17 +1868,17 @@ support the following partial interface, which allows a MediaStream to be assigned directly to a media element. </p> - <dl class="idl" title="partial interface directAssignment"> + <dl class="idl" title="partial interface HTMLMediaElement"> - <dt>attribute MediaStream? sourceObj </dt> + <dt>attribute MediaStream? srcObject </dt> <dd><p>Holds the MediaStream that provides media for this element. This attribute overrides both the <code>src</code> attribute and any <source> elements. Specifically, if - <code>sourceObj</code> is specified, the UA MUST use it as + <code>srcObject</code> is specified, the UA MUST use it as the source of media, even if the <code>src</code> attribute is also set or <source> children are present. If the - value of <code>sourceObj</code> is replaced or set to null + value of <code>srcObject</code> is replaced or set to null the UA MUST re-run the <a href= "http://www.w3.org/TR/html5/embedded-content-0.html#media-element-load-algorithm"> media element load algorithm</a> @@ -1898,7 +1903,7 @@ href="http://www.w3.org/TR/html5/embedded-content-0.html#concept-media-load-resource"> resource fetch phase</a> loads the resource. Both these phases are potentially simplified when using a MediaStream. First of - all, in the case of direct assignment, <code>sourceObj</code> + all, in the case of direct assignment, <code>srcObject</code> takes priority over other means of specifying the resource. Futhermore, it provides the object itself rather than a URI. In this case, there is no need to run the resource selection @@ -1914,7 +1919,7 @@ <li>Whenever the user agent runs the <a href= "http://www.w3.org/TR/html5/embedded-content-0.html#media-element-load-algorithm"> - media element load algorithm</a>, if <code>sourceObj</code> is + media element load algorithm</a>, if <code>srcObject</code> is specified, the UA must immediately go to the <a href= "http://www.w3.org/TR/html5/embedded-content-0.html#concept-media-load-resource"> resource fetch phase</a> of the algorithm. (Note that in this @@ -1934,7 +1939,8 @@ "http://www.w3.org/TR/html5/embedded-content-0.html#concept-media-load-algorithm"> resource selection algorithm</a>, setting the <a href= "http://www.w3.org/TR/html5/embedded-content-0.html#dom-media-readystate"> - <code>media.readyState</code></a> to HAVE_ENOUGH_DATA. </li> + <code>media.readyState</code></a> to HAVE_NOTHING if media is + not yet available and to HAVE_ENOUGH_DATA once it is.</li> <li>For each Track in the MediaStream, including those that are added after the UA enters the <a href= @@ -2031,7 +2037,7 @@ <td>a local URI referencing a MediaStream or the empty string</td> <td>The UA automatically sets the value of this attribute. - When <code>sourceObj</code> is specified the UA MUST + When <code>srcObject</code> is specified the UA MUST set it to the empty string. </td> </tr> @@ -2063,9 +2069,7 @@ class="externalDFN"><code>TimeRanges</code></a> </td> - <td><code>buffered.length</code> MUST return <code>1</code>.<br> - <code>buffered.start(0)</code> MUST return <code>0</code>.<br> - <code>buffered.end(0)</code> MUST return <code>0</code>.<br></td> + <td><code>buffered.length</code> MUST return <code>0</code>.</td> <td>A MediaStream cannot be preloaded. Therefore, the amount buffered is always an empty TimeRange.</td> @@ -2092,13 +2096,14 @@ <td><code>unsigned short</code></td> - <td>HAVE_ENOUGH_DATA</td> + <td>HAVE_NOTHING, HAVE_ENOUGH_DATA</td> - <td>The media is provided locally in real time, so there - is always enough data to play. (A MediaStream with no - Tracks is equivalent to a downloaded file that - contains no playable data.)</td> - + <td>A <code><a>MediaStream</a></code> may be created before there + is any data available, for example when a stream is received from a + remote peer. The value of the <code>readyState</code> of + the media element MUST + be HAVE_NOTHING before the first media arrives + and HAVE_ENOUGH_DATA once the first media has arrived.</td> </tr> <tr> <td> @@ -2113,9 +2118,9 @@ increments linearly in real time whenever the stream is playing.</td> - <td>The value is the current stream position, in seconds. The UA - MUST ignore attempts to set - this attribute.</td> + <td>The value is the current stream position, in seconds. On any + attempt to set this attribute, the user agent must throw an + <code>InvalidStateError</code> exception.</td> </tr> <tr> @@ -2525,6 +2530,15 @@ </li> <li> + <p>If <var>requestedMediaTypes</var> is the empty set, let + <var>error</var> be a new + <code><a>NavigatorUserMediaError</a></code> object whose + <code><a>name</a></code> attribute has the value + <code>NotSupportedError</code> and jump to the step labeled + <em>Error Task</em> below.</p> + </li> + + <li> <p>Let <var>finalSet</var> be an (initially) empty set.</p> </li> @@ -2574,15 +2588,9 @@ <ol> <li> - <p>If the constraint is not supported by the browser, - queue a task to invoke <var>errorCallback</var> with a new - NavigatorUserMediaError object whose name attribute has - the value <code> CONSTRAINT_NOT_SATISFIED </code> and - whose constraintName atribute is set to the name of the - constraint that caused the error and then jump to the step - labeled <em>failure</em> below. </p> - + jump to the step labeled <em>Constraint Failure</em> + below.</p> </li> <li> @@ -2591,17 +2599,10 @@ </li> <li> - <p>If the <var>candidateSet</var> no longer contains at - least one track, queue a task to invoke - <var>errorCallback</var> with a new - NavigatorUserMediaError object whose name attribute has - the value <code> CONSTRAINT_NOT_SATISFIED </code> and - whose constraintName atribute is set to the name of the - constraint that caused the error and then jump to the step - labeled <em>failure</em> below. Otherwise, continue with - the next mandatory constraint.</p> - + least one track, jump to the step labeled + <em>Constraint Failure</em> below. Otherwise, continue + with the next mandatory constraint.</p> </li> </ol> </li> @@ -2644,9 +2645,7 @@ </li> </ol> </li> - </ol> - <ul> <li> <p>Return, and run the remaining steps asynchronously.</p> </li> @@ -2654,7 +2653,7 @@ <li> <p>Optionally, e.g., based on a previously-established user preference, for security reasons, or due to platform limitations, - jump to the step labeled <em>failure</em> below.</p> + jump to the step labeled <em>Permission Failure</em> below.</p> </li> <li> @@ -2691,7 +2690,7 @@ indicator).</p> <p>If the user denies permission, jump to the step labeled - <em>failure</em> below. If the user never responds, this + <em>Constraint Failure</em> below. If the user never responds, this algorithm stalls on this step.</p> </li> @@ -2711,21 +2710,27 @@ </li> <li> - <p><em>Failure</em>:</p> + <p><em>Permission Failure</em>: Let <var>error</var> be a new + <code><a>NavigatorUserMediaError</a></code> object whose + <code><a>name</a></code> attribute has the value + <code>PermissionDeniedError</code> and jump to the step + labeled <em>Error Task</em> below.</p> </li> <li> - - <p>Let <var>error</var> be a new + <p><em>Constraint Failure</em>: Let <var>error</var> be a new <code><a>NavigatorUserMediaError</a></code> object whose <code><a>name</a></code> attribute has the value - <code><a>PERMISSION_DENIED</a></code>. </p> - + <code>ConstraintNotSatisfiedError</code> and whose + <code><a href="#widl-NavigatorUserMediaError-constraintName" + >constraintName</a></code> attribute is set to the name of the + constraint that caused the error.</p> </li> <li> - <p>Queue a task to invoke <var>errorCallback</var> with - <var>error</var> as its argument.</p> + <p><em>Error Task:</em> Queue a task to invoke + <var>errorCallback</var> with <var>error</var> as its argument. + </p> </li> <li style="list-style: none; display: inline"> @@ -2829,43 +2834,30 @@ <h2>NavigatorUserMediaError and NavigatorUserMediaErrorCallback</h2> <dl class="idl" title= - "[NoInterfaceObject] interface NavigatorUserMediaError"> - - <dt>readonly attribute DOMString name</dt> - - <dd>A string representing the type of error. This string must be one - of those defined by the - <code>NavigatorUserMediaErrorName</code> enum for the error object to be - valid.</dd> - - <dt>readonly attribute DOMString? message</dt> - - <dd>A human readable description of the error. This string may vary - between different user agents.</dd> + "[NoInterfaceObject] interface NavigatorUserMediaError : DOMError"> <dt>readonly attribute DOMString? constraintName</dt> - <dd>The name of the constraint that caused the error. Only used for - some types of errors. For NavigatorUserMediaError with a name of - CONSTRAINT_NOT_SATISFIED , the constraintName attribute in the - NavigatorUserMediaError object MUST be set to the name of the - constraint that caused the error. </dd> + <dd> + <p>This attribute is only used for some types of errors. For <code> + <a>NavigatorUserMediaError</a></code> with a name of + <code>ConstraintNotSatisfiedError</code>, this attribute MUST be set + to the name of the constraint that caused the error.</p> + </dd> </dl> - <dl class='idl' title='enum NavigatorUserMediaErrorName'> - <dt> PERMISSION_DENIED </dt> - - <dd> User denied permission for scripts from this origin to access the - media device. </dd> - - <dt> CONSTRAINT_NOT_SATISFIED </dt> - - <dd> One of the mandatory constraints could not be satisfied. </dd> - </dl> + <div class="note"> + <p>Ask the DOM team to extend their list with the following errors.</p> - + <ul> + <li>PermissionDeniedError: User denied permission for scripts from + this origin to access the media device.</li> + <li>ConstraintNotSatisfiedError: One of the mandatory constraints + could not be satisfied.</li> + </ul> + </div> <dl class="idl" title="callback NavigatorUserMediaErrorCallback = void"> <dt>NavigatorUserMediaError error</dt> @@ -3290,7 +3282,31 @@ --> - <h2>Changes since May 29, 2013</h2> + <h2>Changes since July 4, 2013</h2> + + <ol> + <li>Bug 21967: Added paragraph on MediaStreamTrack enabled state and + updated cloning algorithm.</li> + + <li>Bug 22210: Make getUserMedia() algorithm use all numbered items.</li> + + <li>Bug 22250: Fixed accidentally overridden error.</li> + + <li>Bug 22211: Added async error when no valid media type is requested. + + <li>Bug 22216: Made NavigatorUserMediaError extend DOMError.</li> + + <li>Bug 22249: Throw on attempts to set currentTime on media elements + playing MediaStream objects.</li> + + <li>Bug 22246: Made media.buffered have length 0.</li> + + <li>Bug 22692: Updated media element to use HAVE_NOTHING state + before media arrives on the played MediaStream and + HAVE_ENOUGH_DATA as soon as media arrives.</li> + </ol> + + <h2>May 29, 2013</h2> <ol> <li>Bug 22252: fixed usage of MUST in MediaStream() constructor @@ -3300,6 +3316,7 @@ <li>Bug 21967: clarified MediaStreamTrack.enabled state initial value. </li> + <li>Added aspectRatio constraint, capability, and state.</li> <li>Updated usage of MediaStreams in media elements.</li> </ol> --- /sources/public/2011/webrtc/editor/getusermedia.js 2013/07/04 13:38:43 1.14 +++ /sources/public/2011/webrtc/editor/getusermedia.js 2013/08/24 14:10:53 1.15 @@ -19,7 +19,7 @@ // copyrightStart: "2005", // if there is a previously published draft, uncomment this and set its YYYY-MM-DD - prevED: "http://dev.w3.org/2011/webrtc/editor/archives/20130529/getusermedia.html", + prevED: "http://dev.w3.org/2011/webrtc/editor/archives/20130704/getusermedia.html", // if there a publicly available Editor's Draft, this is the link edDraftURI: "http://dev.w3.org/2011/webrtc/editor/getusermedia.html",
Received on Saturday, 24 August 2013 14:10:54 UTC