<?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>24345</bug_id>
          
          <creation_ts>2014-01-21 22:35:25 +0000</creation_ts>
          <short_desc>Remove &quot;default-base-is-moof is set&quot; requirement and clarify what &quot;movie-fragment relative addressing&quot;  means</short_desc>
          <delta_ts>2014-03-03 23:46:59 +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>CR</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Aaron Colwell">acolwell</reporter>
          <assigned_to name="Adrian Bateman [MSFT]">adrianba</assigned_to>
          <cc>cyril.concolato</cc>
    
    <cc>jer.noble</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>98851</commentid>
    <comment_count>0</comment_count>
    <who name="Aaron Colwell">acolwell</who>
    <bug_when>2014-01-21 22:35:25 +0000</bug_when>
    <thetext>I&apos;d like to make the following changes to Section 4 of the ISOBMFF byte stream format spec (https://dvcs.w3.org/hg/html-media/raw-file/default/media-source/isobmff-byte-stream-format.html#iso-media-segments)

Current text:
&quot;The Movie Fragment Box does not use movie-fragment relative addressing or the flag default-base-is-moof is not set.&quot;

Proposed text:
&quot;At least one Track Fragment Header Box(tfhd) has the base-data-offset-present flag set.&quot;

I believe this will more clearly indicates &quot;does not use movie-fragment relative addressing&quot; and allows MSE to accept files that use relative addressing, but don&apos;t specify the default-base-is-moof flag.

Chrome has never enforced the &quot;default-base-is-moof is set&quot; requirement and a large amount of YouTube content does not have this flag set. Requiring this flag be set only marginally reduces implementation complexity and existing MP4 implementations likely handle the &quot;default-base-is-moof not set&quot; case anyways.

FWIW, I also believe making this change will also allow certain legacy SmoothStreaming content to work now with MSE.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>99145</commentid>
    <comment_count>1</comment_count>
    <who name="Cyril Concolato">cyril.concolato</who>
    <bug_when>2014-01-27 10:34:29 +0000</bug_when>
    <thetext>I agree. What&apos;s important is to make sure that the base-data-offset-present flag is not set. Your text also removes the ambiguous &quot;movie-fragment relative addressing&quot; term. I&apos;m fine with it.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>100023</commentid>
    <comment_count>2</comment_count>
    <who name="Jer Noble">jer.noble</who>
    <bug_when>2014-02-07 17:18:48 +0000</bug_when>
    <thetext>(In reply to Cyril Concolato from comment #1)
&gt; I agree. What&apos;s important is to make sure that the base-data-offset-present
&gt; flag is not set. Your text also removes the ambiguous &quot;movie-fragment
&gt; relative addressing&quot; term. I&apos;m fine with it.

(In reply to Aaron Colwell from comment #0)
&gt; I&apos;d like to make the following changes to Section 4 of the ISOBMFF byte
&gt; stream format spec
&gt; (https://dvcs.w3.org/hg/html-media/raw-file/default/media-source/isobmff-
&gt; byte-stream-format.html#iso-media-segments)
&gt; 
&gt; Current text:
&gt; &quot;The Movie Fragment Box does not use movie-fragment relative addressing or
&gt; the flag default-base-is-moof is not set.&quot;
&gt; 
&gt; Proposed text:
&gt; &quot;At least one Track Fragment Header Box(tfhd) has the
&gt; base-data-offset-present flag set.&quot;

While this is a step in the right direction, I believe this goes too far.

The intent of the default-base-is-moof flag is to keep readers from having to completely parse previous &apos;traf&apos; boxes in order to determine the offset of subsequent &apos;traf&apos; boxes.  

If two or more &apos;traf&apos; boxes are contained within the same &apos;moof&apos; box, and both have base-data-offset-present = 0 and default-base-is-moof = 0, the first &apos;traf&apos; will be relative to the enclosing &apos;moof&apos;, but the second &apos;traf&apos; will be relative to end of the data in the first &apos;traf&apos;.  IOW, the first &apos;traf&apos; uses &quot;movie-fragment relative addressing&quot; and the second &apos;traf&apos; does not.

So loosening up the restrictions from &apos;must have default-base-is-moof&apos; to &apos;cannot have base-data-offset-present&apos; goes too far.

Here is my counterproposal:

Current text:
&quot;The Movie Fragment Box does not use movie-fragment relative addressing or the flag default-base-is-moof is not set.&quot;

Proposed text:
&quot;The Movie Fragment Box does not use _movie-fragment relative addressing_.&quot;

and later:

&quot;A Movie Fragment Box uses _movie-fragment relative addressing_ when either of the following conditions are met:
  * Every Track Fragment Box in the Movie Fragment Box has the ‘default-base-is-moof’ flag set
  * The Movie Fragment Box contains a single Track Fragment Box and that box does not have the &apos;base-data-offset-present’ flag set.&quot;

This makes the definition of &quot;movie-fragment relative addressing&quot; unambiguous, and loosens up the restriction only enough to cover the YouTube case.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>100084</commentid>
    <comment_count>3</comment_count>
    <who name="Aaron Colwell">acolwell</who>
    <bug_when>2014-02-08 16:58:18 +0000</bug_when>
    <thetext>I&apos;m fine with Jer&apos;s proposal, but I believe it also means that we&apos;ll have to require that the data-offset-present flag be set on the first Track Fragment Run (&apos;trun&apos;) box in every &apos;traf&apos; box that is present in the &apos;moof&apos;. If I understand the spec correctly, the &apos;moof&apos; relative addressing only comes into play if data-offset-present is set in a &apos;trun&apos; box. Otherwise if no &apos;data_offset&apos; fields are present in any &apos;trun&apos; boxes, the positions are relative to the beginning of the &apos;mdat&apos; box that follows the &apos;moof&apos; and each &apos;trun&apos; requires parsing of the previous &apos;trun&apos; even if that &apos;trun&apos; is in a previous &apos;traf&apos;.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>101800</commentid>
    <comment_count>4</comment_count>
    <who name="Aaron Colwell">acolwell</who>
    <bug_when>2014-03-03 23:46:59 +0000</bug_when>
    <thetext>Change committed
https://dvcs.w3.org/hg/html-media/rev/cad94fce3b90</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>