<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>17071</bug_id>
          
          <creation_ts>2012-05-15 23:34:49 +0000</creation_ts>
          <short_desc>Define how presentation duration is set &amp; updated</short_desc>
          <delta_ts>2012-07-30 20:42:41 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>HTML WG</product>
          <component>Media Source Extensions</component>
          <version>unspecified</version>
          <rep_platform>PC</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Aaron Colwell (c)">acolwell</reporter>
          <assigned_to name="Adrian Bateman [MSFT]">adrianba</assigned_to>
          <cc>mike</cc>
    
    <cc>odinho</cc>
    
    <cc>philipj</cc>
    
    <cc>public-html-media</cc>
    
    <cc>public-html-wg-issue-tracking</cc>
          
          <qa_contact name="HTML WG Bugzilla archive list">public-html-bugzilla</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>67769</commentid>
    <comment_count>0</comment_count>
    <who name="Aaron Colwell (c)">acolwell</who>
    <bug_when>2012-05-15 23:34:49 +0000</bug_when>
    <thetext>The current spec text makes no mention of how the duration attribute on the HTMLMediaElement is set. 

The current Chromium implementation just fetches this value from the first initialization segment and uses that. This is ok if all the initialization segments happen to have the same duration. In the ad-insertion use case though an initialization segment with a significantly different duration may get appended and the web application may want the inserted content to actually increase the duration of the presentation.

Rules about how duration is set and updated need to be defined.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>67770</commentid>
    <comment_count>1</comment_count>
    <who name="Aaron Colwell (c)">acolwell</who>
    <bug_when>2012-05-15 23:35:45 +0000</bug_when>
    <thetext>A possible solution to consider:

Make duration attribute writable and don&apos;t allow a transition to HAVE_METADATA until it is set by the web application or the first initialization segment is appended with a duration. From that point on the duration can only be modified by the web application and future initialization segments won&apos;t effect the duration. If the duration becomes shorter than the previous value, all data in the source buffer beyond the duration will be flushed. If the playback position is beyond the new duration, the HTMLMediaElement will act as if it just reached the end of the presentation and fire all appropriate events.

If we feel it&apos;s necessary to allow the duration to be updatable by a future initialization segment, then we could simply have the web application set the duration to NaN. (I&apos;m not thrilled about this, but interested in comments.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>71672</commentid>
    <comment_count>2</comment_count>
    <who name="Aaron Colwell (c)">acolwell</who>
    <bug_when>2012-07-30 20:42:41 +0000</bug_when>
    <thetext>Spec changes committed.

Revision: 
http://dvcs.w3.org/hg/html-media/rev/087ea42f59c8

Mailing list discussion: 
http://lists.w3.org/Archives/Public/public-html-media/2012Jul/0050.html</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>