Skip to content
Permalink
Browse files
[giow] (0) Define how to handle synthesised audio descriptions that t…
…ake longer to play than the cue with which they are associated

Affected topics: Video and Audio

git-svn-id: http://svn.whatwg.org/webapps@6859 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Dec 9, 2011
1 parent b4d1860 commit 7a827774da15810d84e887cac5f93875b6fefe9a
Showing 3 changed files with 138 additions and 52 deletions.
@@ -29406,12 +29406,12 @@ <h5 id=ready-states><span class=secno>4.8.10.7 </span>Ready states</h5>
<code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> attribute
changed to a value lower than <code title=dom-media-HAVE_FUTURE_DATA><a href=#dom-media-have_future_data>HAVE_FUTURE_DATA</a></code>, and
the element has not <a href=#ended-playback>ended playback</a>, and playback
has not <a href=#stopped-due-to-errors>stopped due to errors</a>, and playback has not
<a href=#paused-for-user-interaction>paused for user interaction</a>, 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>
named <code title=event-media-timeupdate><a href=#event-media-timeupdate>timeupdate</a></code> at
the element, and <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a
simple event</a> named <code title=event-media-waiting><a href=#event-media-waiting>waiting</a></code> at the element.</p>
has not <a href=#stopped-due-to-errors>stopped due to errors</a>, <a href=#paused-for-user-interaction>paused for
user interaction</a>, or <a href=#paused-for-in-band-content>paused for in-band
content</a>, 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> named <code title=event-media-timeupdate><a href=#event-media-timeupdate>timeupdate</a></code> at the element,
and <a href=#queue-a-task>queue a task</a> to <a href=#fire-a-simple-event>fire a simple
event</a> named <code title=event-media-waiting><a href=#event-media-waiting>waiting</a></code> at the element.</p>

</dd>

@@ -29612,7 +29612,8 @@ <h5 id=playing-the-media-resource><span class=secno>4.8.10.8 </span>Playing the
<code title=dom-media-HAVE_NOTHING><a href=#dom-media-have_nothing>HAVE_NOTHING</a></code> state, the
<code title=dom-media-HAVE_METADATA><a href=#dom-media-have_metadata>HAVE_METADATA</a></code> state, or
the <code title=dom-media-HAVE_CURRENT_DATA><a href=#dom-media-have_current_data>HAVE_CURRENT_DATA</a></code> state,
or if the element has <a href=#paused-for-user-interaction>paused for user interaction</a>.</p>
or if the element has <a href=#paused-for-user-interaction>paused for user interaction</a> or
<a href=#paused-for-in-band-content>paused for in-band content</a>.</p>

<p>A <a href=#media-element>media element</a> is said to be <dfn id=potentially-playing>potentially
playing</dfn> when its <code title=dom-media-paused><a href=#dom-media-paused>paused</a></code>
@@ -29623,6 +29624,12 @@ <h5 id=playing-the-media-resource><span class=secno>4.8.10.8 </span>Playing the
on its media controller</a>,
and the element is not a <a href=#blocked-media-element>blocked media element</a>.</p>

<p class=note>A <code title=event-media-waiting><a href=#event-media-waiting>waiting</a></code>
DOM event <a href=#fire-waiting-when-waiting>can be fired</a> as a
result of an element that is <a href=#potentially-playing>potentially playing</a>
stopping playback due to its <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> attribute changing to
a value lower than <code title=dom-media-HAVE_FUTURE_DATA><a href=#dom-media-have_future_data>HAVE_FUTURE_DATA</a></code>.</p>

<p>A <a href=#media-element>media element</a> is said to have <dfn id=ended-playback>ended
playback</dfn> when:</p>

@@ -29681,8 +29688,7 @@ <h5 id=playing-the-media-resource><span class=secno>4.8.10.8 </span>Playing the
controller</a> when the user makes a selection, allowing playback
to resume, the user agent must similarly <a href=#report-the-controller-state>report the controller
state</a> for the <a href=#media-element>media element</a>'s <a href=#current-media-controller>current
media controller</a>.
</p>
media controller</a>.</p>

<p>It is possible for a <a href=#media-element>media element</a> to have both
<a href=#ended-playback>ended playback</a> and <a href=#paused-for-user-interaction>paused for user
@@ -29693,13 +29699,34 @@ <h5 id=playing-the-media-resource><span class=secno>4.8.10.8 </span>Playing the
interaction</a>, 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> named <code title=event-media-timeupdate><a href=#event-media-timeupdate>timeupdate</a></code> at the element.</p>

<p class=note>A <code title=event-media-waiting><a href=#event-media-waiting>waiting</a></code>
DOM event <a href=#fire-waiting-when-waiting>can be fired</a> as a
result of an element that is <a href=#potentially-playing>potentially playing</a>
stopping playback due to its <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> attribute changing to
a value lower than <code title=dom-media-HAVE_FUTURE_DATA><a href=#dom-media-have_future_data>HAVE_FUTURE_DATA</a></code>.</p>
<p>A <a href=#media-element>media element</a> is said to have <dfn id=paused-for-in-band-content>paused for
in-band content</dfn> when its <code title=dom-media-paused><a href=#dom-media-paused>paused</a></code> attribute is false, the <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> attribute is either
<code title=dom-media-HAVE_FUTURE_DATA><a href=#dom-media-have_future_data>HAVE_FUTURE_DATA</a></code> or
<code title=dom-media-HAVE_ENOUGH_DATA><a href=#dom-media-have_enough_data>HAVE_ENOUGH_DATA</a></code> and
the user agent has suspended playback of the <a href=#media-resource>media
resource</a> in order to play content that is temporally anchored
to the <a href=#media-resource>media resource</a> and has a non-zero length, or to
play content that is temporally anchored to a segment of the
<a href=#media-resource>media resource</a> but has a length longer than that
segment. If the <a href=#media-element>media element</a> has a <a href=#current-media-controller>current media
controller</a> when this happens, then the user agent must
<a href=#report-the-controller-state>report the controller state</a> for the <a href=#media-element>media
element</a>'s <a href=#current-media-controller>current media controller</a>. If the
<a href=#media-element>media element</a> has a <a href=#current-media-controller>current media
controller</a> when the user agent unsuspends playback, the user
agent must similarly <a href=#report-the-controller-state>report the controller state</a> for
the <a href=#media-element>media element</a>'s <a href=#current-media-controller>current media
controller</a>.</p>

<p class=example>One example of when a <a href=#media-element>media element</a>
would be <a href=#paused-for-in-band-content>paused for in-band content</a> is when the user
agent is playing <a href=#attr-track-kind-descriptions title=attr-track-kind-descriptions>audio
descriptions</a> from an external WebVTT file, and the
synthesized speech generated for a cue is longer than the time
between the <a href=#text-track-cue-start-time>text track cue start time</a> and the
<a href=#text-track-cue-end-time>text track cue end time</a>.</p>

<p>When the <a href=#current-playback-position>current playback position</a> reaches the end
<hr><p>When the <a href=#current-playback-position>current playback position</a> reaches the end
of the <a href=#media-resource>media resource</a> when the <a href=#direction-of-playback>direction of
playback</a> is forwards, then the user agent must follow these
steps:</p>
@@ -33817,13 +33844,13 @@ <h5 id=mediaevents><span class=secno>4.8.10.16 </span>Event summary</h5>
<td>Playback is ready to start after having been paused or delayed due to lack of <a href=#media-data>media data</a>.
<td><code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> is newly equal to or greater than <code title=dom-media-HAVE_FUTURE_DATA><a href=#dom-media-have_future_data>HAVE_FUTURE_DATA</a></code> and <code title=dom-media-paused><a href=#dom-media-paused>paused</a></code> is false, or <code title=dom-media-paused><a href=#dom-media-paused>paused</a></code> is newly false and <code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> is equal to or greater than <code title=dom-media-HAVE_FUTURE_DATA><a href=#dom-media-have_future_data>HAVE_FUTURE_DATA</a></code>. Even if this event fires, the element might still not be <a href=#potentially-playing>potentially playing</a>, e.g. if
the element is <a href=#blocked-on-its-media-controller>blocked on its media controller</a> (e.g. because the <a href=#current-media-controller>current media controller</a> is paused, or another <a href=#slaved-media-elements title="slaved media elements">slaved media element</a> is stalled somehow, or because the <a href=#media-resource>media resource</a> has no data corresponding to the <a href=#media-controller-position>media controller position</a>), or
the element is <a href=#paused-for-user-interaction>paused for user interaction</a>.
the element is <a href=#paused-for-user-interaction>paused for user interaction</a> or <a href=#paused-for-in-band-content>paused for in-band content</a>.
<tr><td><dfn id=event-media-waiting title=event-media-waiting><code>waiting</code></dfn>
<td><code><a href=#event>Event</a></code>
<td>Playback has stopped because the next frame is not available, but the user agent expects that frame to become available in due course.
<td><code title=dom-media-readyState><a href=#dom-media-readystate>readyState</a></code> is equal to or less than <code title=dom-media-HAVE_CURRENT_DATA><a href=#dom-media-have_current_data>HAVE_CURRENT_DATA</a></code>, and <code title=dom-media-paused><a href=#dom-media-paused>paused</a></code> is false. Either <code title=dom-media-seeking><a href=#dom-media-seeking>seeking</a></code> is true, or the <a href=#current-playback-position>current playback position</a> is not contained in any of the ranges in <code title=dom-media-buffered><a href=#dom-media-buffered>buffered</a></code>. It is possible for playback to stop for other reasons without <code title=dom-media-paused><a href=#dom-media-paused>paused</a></code> being false, but those reasons do not fire this event (and when those situations resolve, a separate <code title=event-media-playing><a href=#event-media-playing>playing</a></code> event is not fired either): e.g.
the element is newly <a href=#blocked-on-its-media-controller>blocked on its media controller</a>, or
<a href=#ended-playback title="ended playback">playback ended</a>, or playback <a href=#stopped-due-to-errors>stopped due to errors</a>, or the element has <a href=#paused-for-user-interaction>paused for user interaction</a>.
<a href=#ended-playback title="ended playback">playback ended</a>, or playback <a href=#stopped-due-to-errors>stopped due to errors</a>, or the element has <a href=#paused-for-user-interaction>paused for user interaction</a> or <a href=#paused-for-in-band-content>paused for in-band content</a>.
<tbody><tr><td><dfn id=event-media-seeking title=event-media-seeking><code>seeking</code></dfn>
<td><code><a href=#event>Event</a></code>
<td>The <code title=dom-media-seeking><a href=#dom-media-seeking>seeking</a></code> IDL attribute changed to true.

0 comments on commit 7a82777

Please sign in to comment.