spec/Overview.html 1.1662 2491 Clarify the requirement that UAs must ma

Clarify the requirement that UAs must make the 'duration' attribute
accurate before playing any media.. (whatwg r2491)

currentTime
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1662.html#dom-media-currenttime
When the length of the media resource changes (e.g. from being unknown to known, or from a previously established length to a new length) the user agent must queue a task to fire a simple event called durationchange at the media element.
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1662.html#durationChange
Index
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1662.html#index
Queue a task to fire a simple event called loadedmetadata at the element.
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1662.html#fire-loadedmetadata
4.8.10.6 Offsets into the media resource
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1662.html#offsets-into-the-media-resource
current playback position
http://people.w3.org/mike/diffs/html5/spec/Overview.1.1662.html#current-playback-position

http://people.w3.org/mike/diffs/html5/spec/Overview.diff.html
http://dev.w3.org/cvsweb/html5/spec/Overview.html?r1=1.1661&r2=1.1662&f=h
http://html5.org/tools/web-apps-tracker?from=2490&to=2491

===================================================================
RCS file: /sources/public/html5/spec/Overview.html,v
retrieving revision 1.1661
retrieving revision 1.1662
diff -u -d -r1.1661 -r1.1662
--- Overview.html 1 Dec 2008 07:54:42 -0000 1.1661
+++ Overview.html 1 Dec 2008 09:53:24 -0000 1.1662
@@ -14332,7 +14332,12 @@
 
          </li>
 
-        </ol></dd>
+        </ol><p class=note>The user agent is <em>required</em> to
+        determine the duration of the <a href=#media-resource>media resource</a> and
+        go through this step before playing.</p> <!-- actually defined
+        in the 'duration' section -->
+
+       </dd>
 
 
        <dt>If the connection is interrupted, causing the user agent to
@@ -14515,16 +14520,21 @@
   same attribute at later times.<h5 id=offsets-into-the-media-resource><span class=secno>4.8.10.6 </span>Offsets into the media resource</h5><p>The <dfn id=dom-media-duration title=dom-media-duration><code>duration</code></dfn>
   attribute must return the length of the <a href=#media-resource>media resource</a>,
   in seconds. If no <a href=#media-data>media data</a> is available, then the
-  attributes must return 0. If <a href=#media-data>media data</a> is available
-  but the length is not known, the attribute must return the
-  Not-a-Number (NaN) value. If the <a href=#media-resource>media resource</a> is
-  known to be unbounded (e.g. a streaming radio), then the attribute
-  must return the positive Infinity value.<p id=durationChange>When the length of the <a href=#media-resource>media
-  resource</a> changes (e.g. from being unknown to known, or from
-  indeterminate to known, or from a previously established length to a
-  new length) the user agent must <a href=#queue-a-task>queue a task</a> to
-  <a href=#fire-a-simple-event>fire a simple event</a> called <code title=event-durationchange><a href=#event-durationchange>durationchange</a></code> at the
-  <a href=#media-element>media element</a>.<p><a href=#media-element title="media element">Media elements</a> have a
+  attributes must return the Not-a-Number (NaN) value. If the
+  <a href=#media-resource>media resource</a> is known to be unbounded (e.g. a
+  streaming radio), then the attribute must return the positive
+  Infinity value.<p>The user agent must determine the duration of the <a href=#media-resource>media
+  resource</a> before playing any part of the <a href=#media-data>media
+  data</a> and before setting <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> to a value equal to
+  or greater than <code title=dom-media-HAVE_METADATA><a href=#dom-media-have_metadata>HAVE_METADATA</a></code>, even if doing
+  so requires seeking to multiple parts of the resource.<p id=durationChange>When the length of the <a href=#media-resource>media
+  resource</a> changes (e.g. from being unknown to known, or from a
+  previously established length to a new length) the user agent must
+  <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple event</a> called
+  <code title=event-durationchange><a href=#event-durationchange>durationchange</a></code> at the
+  <a href=#media-element>media element</a>.<p class=example>If an "infinite" stream ends for some reason,
+  then the duration would change from positive Infinity to the time of
+  the last frame or sample in the stream.<p><a href=#media-element title="media element">Media elements</a> have a
   <dfn id=current-playback-position>current playback position</dfn>, which must initially be
   zero. The current position is a time.<p>The <dfn id=dom-media-currenttime title=dom-media-currentTime><code>currentTime</code></dfn>
   attribute must, on getting, return the <a href=#current-playback-position>current playback
@@ -44139,32 +44149,32 @@
   L. Carlson, Laura Wisewell, Laurens Holst, Lee Kowalkowski, Leif
   Halvard Silli, Lenny Domnitser, L&eacute;onard Bouchet, Leons
   Petrazickis, Logan<!-- on moz irc -->, Loune, Maciej Stachowiak,
-  Magnus Kristiansen<!-- Dashiva -->, Malcolm Rowe, Mark Nottingham,
-  Mark Rowe<!--bdash-->, Mark Schenk, Martijn Wargers, Martin Atkins,
-  Martin D&uuml;rst, Martin Honnen, Masataka Yakura, Mathieu Henri,
-  Matthew Gregan, Matthew Mastracci, Matthew Raymond, Matthew Thomas,
-  Mattias Waldau, Max Romantschuk, Michael 'Ratt' Iannarelli, Michael
-  A. Nachbaur, Michael A. Puls II<!--Shadow2531-->, Michael Carter,
-  Michael Gratton, Michael Nordman, Michael Powers, Michael(tm) Smith,
-  Michel Fortin, Michiel van der Blonk, Mihai &#350;ucan<!-- from
-  ROBO Design -->, Mike Brown, Mike Dierken<!-- S. Mike Dierken -->,
-  Mike Dixon, Mike Schinkel, Mike Shaver, Mikko Rantalainen, Neil
-  Deakin, Neil Soiffer, Olaf Hoffmann, Olav Junker Kj&aelig;r, Oliver
-  Hunt, Peter Karlsson, Peter Kasting, Philip J&auml;genstedt, Philip
-  Taylor, Philip TAYLOR<!-- a different one -->, Rachid Finge, Rajas
-  Moonka, Ralf Stoltze, Ralph Giles, Raphael Champeimont, Rene
-  Saarsoo, Richard Ishida, Rimantas Liubertas, Robert Blaut, Robert
-  O'Callahan, Robert Sayre, Roman Ivanov, Ryan King, S. Mike Dierken,
-  Sam Kuper, Sam Ruby, Sam Weinig, Scott Hess, Sean Knapp, Shaun
-  Inman, Silvia Pfeiffer, Simon Pieters, Stefan Haustein, Steffen
-  Meschkat, Stephen Ma, Steve Faulkner, Steve Runyon, Steven Garrity,
-  Stewart Brodie, Stuart Parmenter, Sunava Dutta, Tantek &Ccedil;elik,
-  Terrence Wood, Thomas Broyer, Thomas O'Connor, Tim Altman, Tim
-  Johansson, Travis Leithead, Tyler Close, Vladimir
-  Vuki&#263;evi&#263;, Wakaba, Wayne Pollock, Wellington Fernando
-  de Macedo, William Swanson, Wolfram Kriesing, Yi-An Huang, and
-  &Oslash;istein E. Andersen, for their useful and substantial
-  comments.<p>Thanks also to everyone who has ever posted about HTML5 to their
+  Magnus Kristiansen<!-- Dashiva -->, Maik Merten, Malcolm Rowe, Mark
+  Nottingham, Mark Rowe<!--bdash-->, Mark Schenk, Martijn Wargers,
+  Martin Atkins, Martin D&uuml;rst, Martin Honnen, Masataka Yakura,
+  Mathieu Henri, Matthew Gregan, Matthew Mastracci, Matthew Raymond,
+  Matthew Thomas, Mattias Waldau, Max Romantschuk, Michael 'Ratt'
+  Iannarelli, Michael A. Nachbaur, Michael A. Puls
+  II<!--Shadow2531-->, Michael Carter, Michael Gratton, Michael
+  Nordman, Michael Powers, Michael(tm) Smith, Michel Fortin, Michiel
+  van der Blonk, Mihai &#350;ucan<!-- from ROBO Design -->, Mike
+  Brown, Mike Dierken<!-- S. Mike Dierken -->, Mike Dixon, Mike
+  Schinkel, Mike Shaver, Mikko Rantalainen, Neil Deakin, Neil Soiffer,
+  Olaf Hoffmann, Olav Junker Kj&aelig;r, Oliver Hunt, Peter Karlsson,
+  Peter Kasting, Philip J&auml;genstedt, Philip Taylor, Philip
+  TAYLOR<!-- a different one -->, Rachid Finge, Rajas Moonka, Ralf
+  Stoltze, Ralph Giles, Raphael Champeimont, Rene Saarsoo, Richard
+  Ishida, Rimantas Liubertas, Robert Blaut, Robert O'Callahan, Robert
+  Sayre, Roman Ivanov, Ryan King, S. Mike Dierken, Sam Kuper, Sam
+  Ruby, Sam Weinig, Scott Hess, Sean Knapp, Shaun Inman, Silvia
+  Pfeiffer, Simon Pieters, Stefan Haustein, Steffen Meschkat, Stephen
+  Ma, Steve Faulkner, Steve Runyon, Steven Garrity, Stewart Brodie,
+  Stuart Parmenter, Sunava Dutta, Tantek &Ccedil;elik, Terrence Wood,
+  Thomas Broyer, Thomas O'Connor, Tim Altman, Tim Johansson, Travis
+  Leithead, Tyler Close, Vladimir Vuki&#263;evi&#263;, Wakaba,
+  Wayne Pollock, Wellington Fernando de Macedo, William Swanson,
+  Wolfram Kriesing, Yi-An Huang, and &Oslash;istein E. Andersen, for
+  their useful and substantial comments.<p>Thanks also to everyone who has ever posted about HTML5 to their
   blogs, public mailing lists, or forums, including the <a href=http://lists.w3.org/Archives/Public/public-html/>W3C
   public-html list</a> and the <a href=http://www.whatwg.org/mailing-list>various WHATWG lists</a>.

Received on Monday, 1 December 2008 09:57:01 UTC