W3C home > Mailing lists > Public > public-texttracks@w3.org > September 2012

Overlapping cues and rendering behavior

From: Victor Carbune <victor.carbune@gmail.com>
Date: Wed, 26 Sep 2012 20:14:41 +0300
Message-ID: <CA+nQPrkjH+53RpuT-BasjXrfwc2St4pa4Z-N7BZRUfQ2ecvqCw@mail.gmail.com>
To: public-texttracks@w3.org
Hi Cyril,

On Wed, Sep 26, 2012 at 6:41 PM, Cyril Concolato
<cyril.concolato@telecom-paristech.fr> wrote:
> Hi again,
> I've made a small test and the rendering in Opera and Chrome is different. I
> don't know which one is correct.
> http://perso.telecom-paristech.fr/~concolat/html5_tests/webvtt-overlapping.html
> <http://perso.telecom-paristech.fr/%7Econcolat/html5_tests/webvtt-overlapping.html>
> In Chrome, when 2 cues are active at the same time, and the first one
> becomes inactive, the second one is shifted down by one line. The next
> active cue (the third one) will be displayed on the line above the second
> cue.
> In Opera, the remaining active cue is not shifted, it does not move. The
> next active cue (third cue) will take the empty space below the active cue.
> This leads to strange results.
> In the above test, this is visible at time 16. Opera displays cue 6, 4, 5
> (from bottom line to top) while Chrome displays 4, 5, 6 (bottom to top).
> I tend to prefer Chrome's behavior as this gives the same result if you
> split the overlapping cues so that they do not overlap (see my post for more
> details http://concolato.wp.mines-telecom.fr/2012/09/12/webvtt-streaming/).
> Comments?
Nice catch of the difference. In Chrome this happens because all the
cues are repainted (in the text track cue order [1]), instead of only the
ones that have not been already added to the output.

The specification indeed mentions that cues already painted should
remain there ("For each text track cue cue in cues that has not yet
had corresponding CSS boxes added to output, in text track cue order,
run the following substeps"), so with the current state of the spec
this can be considered a bug in Chrome.

However, I also think that your example is a good argument to
re-render the cues in corresponding order from the beginning.

[1] http://www.whatwg.org/specs/web-apps/current-work/multipage/the-video-element.html#text-track-cue-order

Received on Wednesday, 26 September 2012 17:15:34 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:27:20 UTC