TextTrack questions

Hi,

I have a few questions about TextTrack behavior for modified cues and
in-band tracks. Please forgive me if some of these answers are in the spec
and I didn't happen to find them. I did look. :)

1. If an attribute on a TextTrackCue like id or startTime is modified, is
this cue supposed to be internally identified in the UA as "the cue
formerly known as Y in the original source file"?

In the case of out-of-band text tracks this seems like a non-issue because
the cues are inserted into the TextTrackList only at the beginning of
playback when they are parsed. The parser visits the source data once and
inserts cues only once.

In the case of in-band tracks it is not clear what should be done because
seeking back to an earlier portion of the clip would cause the file format
parser to parse the cue data again and potentially try to insert it again.
If the original cue was modified, then the cue data in the file and the
values in the existing TextTrackCue wouldn't match so simple duplicate
detection would not work.

Is the UA expected to keep a unique internal id for each in-band
TextTrackCue it creates so that it doesn't reinsert a cue that was inserted
previously, but was modified?

I couldn't find anything in the HTML5 spec that clarified this situation.


2. When using the Media Source Extensions, it is possible to append data
over the top of previously appended data to replace it. If such an append
occurs that triggers the removal of a cue from the SourceBuffer then it's
pretty clear that the TextTrackCue can be removed from the TextTrackList if
it hasn't been modified. If the TextTrackCue has been modified though,
should the UA remove it because the underlying cue in the SourceBuffer was
removed, or should it leave the modified cue in the TextTrackList?

My assumption is that unmodified cues should be removed, but modified ones
should stay, but I just wanted to double check this assumption.


3. If we have an append that removes a cue and then another one that adds
back the cue, then the proper behavior would be to resolve the first append
according to the answer to #2 and then insert a new TextTrackCue for the
second append since there is no way to know for sure whether it was related
to the original cue. Does this sound reasonable?

Thanks for your help,
Aaron

Received on Wednesday, 15 January 2014 22:02:38 UTC