[html5] r7446 - [giow] (1) Step one: Make snap-to-line cues not overlap the overscan area in the [...]

whatwg at whatwg.org whatwg at whatwg.org
Tue Oct 9 14:30:23 PDT 2012


Author: ianh
Date: 2012-10-09 14:30:22 -0700 (Tue, 09 Oct 2012)
New Revision: 7446

Modified:
   source
Log:
[giow] (1) Step one: Make snap-to-line cues not overlap the overscan area in the direction of the line stacking (i.e. vertically for english captions).
Fixing https://www.w3.org/Bugs/Public/show_bug.cgi?id=16864
Affected topics: Video Text Tracks

Modified: source
===================================================================
--- source	2012-10-09 19:10:12 UTC (rev 7445)
+++ source	2012-10-09 21:30:22 UTC (rev 7446)
@@ -114440,6 +114440,45 @@
 
          <li>
 
+          <p><strong>Horizontal</strong>: Let <var title="">margin</var> be a user-agent-defined
+          vertical length which will be used to define a margin at the top and bottom edges of the
+          video into which cues will not be placed. In situations with overscan, this margin should
+          be sufficient to place all cues within the title-safe area. In the absence of overscan,
+          this value should be picked for aesthetics (to avoid text being aligned precisely on the
+          bottom edge of the video, which can be ugly).</p>
+
+          <p><strong>Vertical</strong>: Let <var title="">margin</var> be a user-agent-defined
+          horizontal length which will be used to define a margin at the left and right edges of the
+          video into which cues will not be placed. In situations with overscan, this margin should
+          be sufficient to place all cues within the title-safe area. In the absence of overscan,
+          this value should be picked for aesthetics (to avoid text being aligned precisely on the
+          left or right edges of the video, which can be ugly).</p>
+
+         </li>
+
+         <li>
+
+          <p><strong>Horizontal</strong>: Let <var title="">full dimension</var> be the height of
+          <var title="">video</var>'s rendering area.</p>
+
+          <p><strong>Vertical</strong>: Let <var title="">full dimension</var> be the width of <var
+          title="">video</var>'s rendering area.</p>
+
+          <p>These dimensions must not be adjusted for overscan. (The algorithm does that
+          separately.)</p>
+
+         </li>
+
+         <li>
+
+          <p>Let <var title="">max dimension</var> be <span title=""><var
+          title="">full dimension</var> - (2 × <var
+          title="">margin</var>)</span>.</p>
+
+         </li>
+
+         <li>
+
           <p><strong>Horizontal</strong>: Let <var title="">step</var>
           be the height of the first line box in <var
           title="">boxes</var>.</p>
@@ -114470,19 +114509,12 @@
 
          <li>
 
-          <p><strong>Horizontal</strong>: If <var title="">line
-          position</var> is less than zero then increase <var
-          title="">position</var> by the height of the <var
-          title="">video</var>'s rendering area, and negate <var
-          title="">step</var> (so its value is now minus the height of
-          the first line box in <var title="">boxes</var>).</p>
-
-          <p><strong>Vertical</strong>: If <var title="">line
-          position</var> is less than zero then increase <var
-          title="">position</var> by the width of the <var
-          title="">video</var>'s rendering area, and negate <var
+          <p>If <var title="">line position</var> is less than zero then increase <var
+          title="">position</var> by <var title="">max dimension</var>, and negate <var
           title="">step</var>.</p>
 
+          <p>Otherwise, increase <var title="">position</var> by <var title="">margin</var>.</p>
+
          </li>
 
          <li>
@@ -114503,32 +114535,38 @@
 
          <li><p>Let <var title="">switched</var> be false.</p></li>
 
-         <li><p><i>Step loop</i>: If none of the boxes in <var
-         title="">boxes</var> would overlap any of the boxes in <var
-         title="">output</var>, and all the boxes in <var
-         title="">output</var> are within the <var
-         title="">video</var>'s rendering area, then jump to the step
-         labeled <i>done positioning</i> below.</p></li>
+         <li>
 
+          <p><strong>Horizontal</strong>: Let <var title="">title area</var> be a box that covers
+          all of the <var title="">video</var>'s rendering area except for a height of <var
+          title="">margin</var> at the top of the rendering area and a height of <var
+          title="">margin</var> at the bottom of the rendering area.</p>
+
+          <p><strong>Vertical</strong>: Let <var title="">title area</var> be a box that covers all
+          of the <var title="">video</var>'s rendering area except for a width of <var
+          title="">margin</var> at the left of the rendering area and a width of <var
+          title="">margin</var> at the right of the rendering area.</p>
+
+         </li>
+
+         <li><p><i>Step loop</i>: If none of the boxes in <var title="">boxes</var> would overlap
+         any of the boxes in <var title="">output</var>, and all of the boxes in <var
+         title="">output</var> are entirely within the <var title="">title area</var> box, then jump
+         to the step labeled <i>done positioning</i> below.</p></li>
+
          <li>
 
-          <p><strong>Horizontal</strong>: If <var title="">step</var>
-          is negative and the top of the first line box in <var
-          title="">boxes</var> is now above the top of the <var
-          title="">video</var>'s rendering area, or if <var
-          title="">step</var> is positive and the bottom of the first
-          line box in <var title="">boxes</var> is now below the
-          bottom of the <var title="">video</var>'s rendering area,
-          jump to the step labeled <i>switch direction</i>.</p>
+          <p><strong>Horizontal</strong>: If <var title="">step</var> is negative and the top of the
+          first line box in <var title="">boxes</var> is now above the top of the <var
+          title="">title area</var>, or if <var title="">step</var> is positive and the bottom of
+          the first line box in <var title="">boxes</var> is now below the bottom of the <var
+          title="">title area</var>, jump to the step labeled <i>switch direction</i>.</p>
 
-          <p><strong>Vertical</strong>: If <var title="">step</var> is
-          negative and the left edge of the first line box in <var
-          title="">boxes</var> is now to the left of the left edge of
-          the <var title="">video</var>'s rendering area, or if <var
-          title="">step</var> is positive and the right edge of the
-          first line box in <var title="">boxes</var> is now to the
-          right of the right edge of the <var title="">video</var>'s
-          rendering area, jump to the step labeled <i>switch
+          <p><strong>Vertical</strong>: If <var title="">step</var> is negative and the left edge of
+          the first line box in <var title="">boxes</var> is now to the left of the left edge of the
+          <var title="">title area</var>, or if <var title="">step</var> is positive and the right
+          edge of the first line box in <var title="">boxes</var> is now to the right of the right
+          edge of the <var title="">title area</var>, jump to the step labeled <i>switch
           direction</i>.</p>
 
          </li>




More information about the Commit-Watchers mailing list