W3C home > Mailing lists > Public > public-tt@w3.org > May 2017

[ttml2] Troubles with ttp:mediaOffset

From: Nigel Megitt via GitHub <sysbot+gh@w3.org>
Date: Fri, 19 May 2017 13:43:45 +0000
To: public-tt@w3.org
Message-ID: <issues.opened-229979269-1495201423-sysbot+gh@w3.org>
nigelmegitt has just created a new issue for https://github.com/w3c/ttml2:

== Troubles with ttp:mediaOffset ==
See #125 for background. Raising this to capture my thoughts on mediaOffset that I have previously discussed during face to face meetings.

There are multiple problems with `ttp:mediaOffset` as currently specified:

### Problems

#### Multiple presentation contexts

`ttp:mediaOffset` appears to require that exactly one related media object is relevant when deciding what media offset to apply at presentation time, in other words it fails if there is more than one presentation context, and different presentation contexts have different offset requirements. In general TTML documents are likely to be reused in different presentation contexts in an "author once, use many times" pattern.

#### Duplication of functionality present elsewhere

It duplicates functionality more usually put into wrapper formats - if it is only metadata from the TTML context then it should not be in the `ttp` namespace. It is unclear whether some additional time computation is required at presentation time or if the offset value should simply be transferred to the wrapper format. This ambiguity is likely to cause interoperability problems, especially if the offset is in some implementations effectively processed twice.

#### Circular definition

In Terminology:

> [root temporal extent]
> The temporal extent (interval) defined by the temporal beginning and ending of a document instance in relationship with some external application or presentation context.

In §7.2.10 ttp:mediaOffset
> The ttp:mediaOffset attribute is used to specify the temporal offset between the begin time of the root temporal extent and the begin time of a related media object ...

Expanding these, we seem to have a temporal offset between the beginning of a (temporal extent defined by the temporal beginning and ending of a document instance in relationship with some ... presentation context) and the begin time of a related media object. This doesn't appear to make any sense. If it is _defining_ the relationship between the document instance's begin time and the presentation context, then the above wording in §7.2.10 doesn't say that.

I am taking it that a presentation context includes possible playback of some related media object.

#### SMPTE timebase application problem

If `ttp:mediaOffset` applies to smpte timebase then this will usually result in playback failure - it is effectively saying although the author used SMPTE timecode to align the subtitles with the video, that timecode alignment is in fact wrong. The correct solution to this problem is to fix the times in the document instance, not to apply a media offset.

#### Media timebase application problem

It is a possible interpretation that `ttp:mediaOffset`specifies the relationship between media time and the document's timeline, in which case it cannot apply if timebase is "media", since in that timebase the relationship is already defined. 

#### Handling of negative times is undefined.

`ttp:mediaOffset`, if interpreted as being something that modifies all the computed times, can result in negative times, whose semantic is undefined.

#### Does not identify beginning of root temporal extent

`ttp:mediaOffset` does not actually support the (possibly orthogonal) need to define the beginning of intended presentation, i.e. the entry point in the document instance's timeline, or the point before which any ISDs should be truncated. This is asymmetric with the existing ability to specify the end of presentation, which can be done by putting a `dur` or `end` attribute on, say, the `body` element, or if the intent is for indefinite end, the end time can be left unspecified on some leaf elements. Currently all documents appear to begin at time zero regardless of the intended playback begin point. 

### Proposed resolution

1. Remove `ttp:mediaOffset`.
2. Add a `ttp:temporalBegin` (name can be discussed) that does not modify the syncbase of the root element but truncates all ISDs beginning before it so that the content does not appear. This deals with the "pre-roll" scenario for example, and can also safely be carried over to wrapper formats for example to derive fragment or segment times without needing to modify the computed times in the document instance. In other words, if duplicated in a wrapper it remains "safe".


Please view or discuss this issue at https://github.com/w3c/ttml2/issues/323 using your GitHub account
Received on Friday, 19 May 2017 13:43:51 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 5 October 2017 18:24:40 UTC