<?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>20901</bug_id>
          
          <creation_ts>2013-02-07 23:59:14 +0000</creation_ts>
          <short_desc>contiguous splice/append without knowing media segment internal timestamps</short_desc>
          <delta_ts>2013-05-06 21:59:44 +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>All</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="Michael Thornburgh">mthornbu</reporter>
          <assigned_to name="Aaron Colwell (c)">acolwell</assigned_to>
          <cc>acolwell</cc>
    
    <cc>acolwell</cc>
    
    <cc>adrianba</cc>
    
    <cc>mike</cc>
    
    <cc>public-html-media</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>82723</commentid>
    <comment_count>0</comment_count>
    <who name="Michael Thornburgh">mthornbu</who>
    <bug_when>2013-02-07 23:59:14 +0000</bug_when>
    <thetext>some media formats, such as Apple&apos;s HTTP Live Streaming (HLS), do not include information about the internal timestamps of media segments in the format&apos;s index/manifest files (.m3u8 in the HLS case). the HLS semantic is that media segments are contiguous in their listed order, and timestamps are used only for media track synchronization within a continuity era.  continuity eras are delimited by a discontinuity indicator in the manifest file (.m3u8 in this case).

the current Media Source Extensions specification requires the application to know the internal media timestamps of media segments in order to position the segments in the time line.  this information is unnecessary in the simple (linear contiguous append) case and, as stated above, may not be readily available without parsing the media segments themselves.

there should be a way to perform at least a simple append of media segments into the decoder buffer for contiguous linear playback without knowing the internal media segment timestamps, while maintaining cross-track synchronization even when there are media stream/track discontinuities.

a suggested solution is to provide an indicator to abort() to signal &quot;beginning of next segment is aligned to timestampOffset&quot;.  in the case of MPEG-2 Transport Streams, this would modify the calculation of MPEG2TS_timestampOffset at abort() and the following append; other media types would require the definition of a similar timestamp shift facility.

this suggested solution may not be sufficient to maintain synchronization across multiple tracks when they are being appended separately.  further study and discussion is required.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84001</commentid>
    <comment_count>1</comment_count>
    <who name="Aaron Colwell (c)">acolwell</who>
    <bug_when>2013-03-05 17:28:11 +0000</bug_when>
    <thetext>Changes committed.
https://dvcs.w3.org/hg/html-media/rev/dcd406812201</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>86589</commentid>
    <comment_count>2</comment_count>
    <who name="Adrian Bateman [MSFT]">adrianba</who>
    <bug_when>2013-04-23 17:59:52 +0000</bug_when>
    <thetext>I&apos;m reopening this bug based on the discussion on the call:
http://www.w3.org/2013/04/09-html-media-minutes.html#item04

The result of the change to fix this bug is that out-of-order appends are prohibited without calling abort(). We&apos;ve observed that this results in needing to commonly call abort before each fragment is appended, which is unnecessary for some formats.

It seems like a solution to the discontinuity issue ought to be needed only when using a format that has this characteristic. Prototyping support for this feature broke all our tests for ISO BMFF.

We don&apos;t have a concrete proposal for how to solve this but wonder if something can be added to the appendXXX() methods so that applications using formats that need to deal with discontinuity can indicate whether the append is a continuation. For formats that contain timestamp data, this should not be needed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>86621</commentid>
    <comment_count>3</comment_count>
    <who name="Michael Thornburgh">mthornbu</who>
    <bug_when>2013-04-23 20:46:54 +0000</bug_when>
    <thetext>both of the current &quot;AbortMode&quot;s are useful, and required for appending discontinuous media broken into separate files, for example separated video and audio. one would use &quot;continuation&quot; with one sequence (say, video) to establish what the new timestamps are, and use &quot;timestampOffset&quot; with the other sequence(s) (say, audio) after discovering what the timestampOffset is from the first sequence, to keep all sequences synchronized by their timestamps.  without this capability and just the equivalent of &quot;continuation&quot;, the separate sequences could go out of sync if they don&apos;t start all at exactly the same timestamp (which might easily be the case for separated video and audio tracks).

how about keeping the current AbortMode optional parameter for abort(), but allow out-of-order appends without calling abort for all media containers which can reasonably accommodate this, and for situations where you want the discontinuity behavior for formats like ISO BMFF?  it might only be necessary for MPEG-2 TS.

the behavior for abort() when called with no parameters should have been the same as before the AbortMode parameter was added.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>86623</commentid>
    <comment_count>4</comment_count>
    <who name="Adrian Bateman [MSFT]">adrianba</who>
    <bug_when>2013-04-23 20:55:54 +0000</bug_when>
    <thetext>Discussed in F2F meeting - agreement that we want to make a change here. Editors will discuss and come up with a proposal that removes the overhead from applications that only deal with formats that don&apos;t need this capability. We still want to support this for formats like TS.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>87267</commentid>
    <comment_count>5</comment_count>
    <who name="Aaron Colwell">acolwell</who>
    <bug_when>2013-05-06 15:42:12 +0000</bug_when>
    <thetext>For the record, here is the discussion of the new proposal on public-html-media
http://lists.w3.org/Archives/Public/public-html-media/2013May/0000.html</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>87291</commentid>
    <comment_count>6</comment_count>
    <who name="Aaron Colwell">acolwell</who>
    <bug_when>2013-05-06 21:59:44 +0000</bug_when>
    <thetext>Changes committed
https://dvcs.w3.org/hg/html-media/rev/9ff5e42736b6</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>