<?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>14106</bug_id>
          
          <creation_ts>2011-09-11 15:42:40 +0000</creation_ts>
          <short_desc>&lt;track&gt; Chapter tree construction algorithm requires source order; is broken using sorted cue order</short_desc>
          <delta_ts>2011-09-22 09:17:53 +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>HTML5 spec</component>
          <version>unspecified</version>
          <rep_platform>Other</rep_platform>
          <op_sys>other</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc>http://www.whatwg.org/specs/web-apps/current-work/#text-tracks-describing-chapters</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P3</priority>
          <bug_severity>blocker</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>contributor</reporter>
          <assigned_to name="Ian &apos;Hixie&apos; Hickson">ian</assigned_to>
          <cc>annacc</cc>
    
    <cc>eoconnor</cc>
    
    <cc>eric.carlson</cc>
    
    <cc>giles</cc>
    
    <cc>ian</cc>
    
    <cc>mike</cc>
    
    <cc>philipj</cc>
    
    <cc>public-html-admin</cc>
    
    <cc>public-html-wg-issue-tracking</cc>
    
    <cc>silviapfeiffer1</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>56639</commentid>
    <comment_count>0</comment_count>
    <who name="">contributor</who>
    <bug_when>2011-09-11 15:42:40 +0000</bug_when>
    <thetext>Specification: http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html
Multipage: http://www.whatwg.org/C#text-tracks-describing-chapters
Complete: http://www.whatwg.org/c#text-tracks-describing-chapters

Comment:
Construct chapter from from sorted cue order (drop source order depencies)

Posted from: 65.51.202.21
User agent: Opera/9.80 (Windows NT 6.1; U; en) Presto/2.9.168 Version/11.51</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56642</commentid>
    <comment_count>1</comment_count>
    <who name="Philip Jägenstedt">philipj</who>
    <bug_when>2011-09-11 15:53:39 +0000</bug_when>
    <thetext>Comments from the Open Video Conference, with implementors of Opera, Firefox,
Chrome and Safari discussing WebVTT.

http://people.opera.com/philipj/2011/09/ovc/demos/chapters.html was written to demostrate the chapter tree construction. Since the algorithm uses source order, it cannot be emulated using scripts operating on the cues. Problems:

1. We don&apos;t want to keep track of two order of the cues, because there&apos;s no reason to module this bug.

2. If you use the &quot;text track cue order&quot; the nesting will be wrong for chapters with the same start time, some chapters will be dropped. To see this, comment out the following from the example:

/*
  list.sort(function(a, b) {
    if (a.startTime != b.startTime)
      return a.startTime - b.startTime;
    return b.endTime - a.endTime;
  });
*/

Suggestion solution:

Use the &quot;text track cue order&quot; but modify that concept to sort first by increasing start time, then by decreasing end time, then by insertion order. This solved problem, and actually improves the rendering order of captions that share start time but not end time (the top and shorter cue goes away first).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>56646</commentid>
    <comment_count>2</comment_count>
    <who name="Philip Jägenstedt">philipj</who>
    <bug_when>2011-09-11 16:08:32 +0000</bug_when>
    <thetext>s/demostrate/demonstrate/
s/module/modulo/

(Dear W3C, please let me edit comments after posting.)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57016</commentid>
    <comment_count>3</comment_count>
    <who name="Ian &apos;Hixie&apos; Hickson">ian</who>
    <bug_when>2011-09-20 00:13:36 +0000</bug_when>
    <thetext>Done.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>57017</commentid>
    <comment_count>4</comment_count>
    <who name="">contributor</who>
    <bug_when>2011-09-20 00:14:08 +0000</bug_when>
    <thetext>Checked in as WHATWG revision r6557.
Check-in comment: Change the text track cue order so that it reverse-sorts on end time, since that results in better rendering and fixes some chapter issues. Also, better define the order of events for multiple cues that started at the same time with different end times.
http://html5.org/tools/web-apps-tracker?from=6556&amp;to=6557</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>