Re: [imsc] image based subtitle positioning

On Wed, Oct 8, 2014 at 10:22 AM, Glenn Adams <glenn@skynav.com> wrote:

> To reaffirm what Nigel said, we have already added this support to TTML2
> in the form of "inline region" specifications. about which see [1]. One can
> either specify a region child of a div or p, called an *explicit inline
> region specification* or use a shorthand of specifying
> tts:{origin,extent} directly on a div or p, called an *implied inline
> region specification*.
>
>
> [1] file:///Users/glenn/work/w3c/ttml/ttml2/spec/ttml2.html#semantics-inline-regions
>

Sorry, that should be:

[1]
https://dvcs.w3.org/hg/ttml/raw-file/tip/ttml2/spec/ttml2.html#semantics-inline-regions


>
> On Tue, Oct 7, 2014 at 3:28 PM, Simon Hailes <
> Simon.Hailes@screensystems.tv> wrote:
>
>>  Dear all,
>>
>>
>>
>> As the public review period nears its end, I’d like to highlight a
>> positive addition to the imsc spec to facilitate image based subtitling.
>>
>>
>>
>> A basic image based subtitling script file will normally contain:
>>
>> Incue/Outcue
>>
>> Image name/url
>>
>> Image position
>>
>> Optionally, image size may be specified, and the overall size of the
>> canvas may be specified.
>>
>>
>>
>>
>>
>> Imsc by inclusion of backgroundimage just about allows for these.  But
>> the specification of image size and position is very convoluted.
>>
>>
>>
>> For image based subtitling, position and size of the image in relation to
>> the video is paramount.
>>
>>
>>
>>
>>
>> It would be really good if tts:origin and tts:extent were enabled on div
>> for image based subtitling; at the moment I cannot see how they are
>> allowed.  Please correct me and include a sample in the document if I am
>> wrong.
>>
>> It would also be good to be explicit about image scaling.  Ideally, the
>> image should be scaled to match the specified image extent (with some notes
>> that if this scaling is close to 1:1 after taking into account player size,
>> etc., then the decoder may prefer not to scale to retain quality).
>>
>>
>>
>>
>>
>> This modification would make image based subtitling in imsc a relatively
>> simple and easy to understand construct.  It makes it almost as simple to
>> write as current extant image + script formats, and (I would imagine) make
>> it relative easy to parse.
>>
>>
>>
>>
>>
>>
>>
>> Modified example from
>> http://en.wikipedia.org/wiki/User:Cwmwenallt/SMPTE-TT
>> <http://en.wikipedia..org/wiki/User:Cwmwenallt/SMPTE-TT> (i’m not
>> claiming this was correct to start with!).
>>
>>
>>
>>
>>
>> <tt xmlns:smpte="http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt"
>>
>>    xmlns="http://www.w3.org/ns/ttml"
>>
>>    xmlns:ttm="http://www.w3.org/ns/ttml#metadata"
>>
>>    xmlns:tts='http://www.w3.org/ns/ttml#styling'
>>
>>    xml:lang="en">
>>
>> <head>
>>
>>    <layout>
>>
>>      <region xml:id="imageRegion" tts:color="transparent" tts:origin="0%
>> 0%" tts:extent="100% 100%" >
>>
>>        <set begin="0.19305s" end="0.21581s" tts:origin="0px 2px"
>> tts:extent="4px 8px" />
>>
>>        <set begin="5.89876s" end="8.09467s" tts:origin="230px 50px"
>> tts:extent="243px 58px" />
>>
>>        <set begin="8.20106s" end="10.1922s" tts:origin="202px 50px"
>> tts:extent="302px 64px" />
>>
>>        <set begin="10.3032s" end="12.2943s" tts:origin="180px 402px"
>> tts:extent="341px 32px" />
>>
>>      </region>
>>
>>    </layout>
>>
>> </head>
>>
>> <body>
>>
>>    <div region="imageRegion">
>>
>>      <div begin="0.19305s" end="0.21581s"
>> smpte:backgroundImage="Subtitles_EN/SPU0.png">
>>
>>        <p>[Example SMPTE-TT file]</p>
>>
>>      </div>
>>
>>      <div begin="5.89876s" end="8.09467s"
>> smpte:backgroundImage="Subtitles_EN/SPU1.png">
>>
>>        <p>Hello Wikipedia</p>
>>
>>      </div>
>>
>>      <div begin="8.20106s" end="10.1922s"
>> smpte:backgroundImage="Subtitles_EN/SPU2.png">
>>
>>        <p>This is a basic Example</p>
>>
>>      </div>
>>
>>      <div begin="10.3032s" end="12.2943s"
>> smpte:backgroundImage="Subtitles_EN/SPU3.png" >
>>
>>        <p>of pop on style captioning with preformatted background
>> images</p>
>>
>>      </div>
>>
>>    </div>
>>
>>  </body>
>>
>> </tt>
>>
>>
>>
>>
>>
>> Becomes (I did not add the required namespace):
>>
>>
>>
>> <tt xmlns:smpte="http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt"
>>
>>    xmlns="http://www.w3.org/ns/ttml"
>>
>>    xmlns:ttm="http://www.w3.org/ns/ttml#metadata"
>>
>>    xmlns:tts='http://www.w3.org/ns/ttml#styling'
>>
>>    xml:lang="en">
>>
>> <head>
>>
>>    <layout>
>>
>>      <region xml:id="imageRegion" tts:color="transparent" tts:origin="0%
>> 0%" tts:extent="100% 100%" >
>>
>>      </region>
>>
>>    </layout>
>>
>> </head>
>>
>> <body>
>>
>>    <div region="imageRegion">
>>
>>      <div begin="0.19305s" end="0.21581s"
>> smpte:backgroundImage="Subtitles_EN/SPU0.png" tts:origin="0px 2px"
>> tts:extent="4px 8px" >
>>
>>        <ittm:altText>[Example SMPTE-TT file]</ittm:altText>
>>
>>      </div>
>>
>>      <div begin="5.89876s" end="8.09467s"
>> smpte:backgroundImage="Subtitles_EN/SPU1.png" tts:origin="230px 50px"
>> tts:extent="243px 58px" >
>>
>>        <ittm:altText>Hello Wikipedia</ittm:altText>
>>
>>      </div>
>>
>>      <div begin="8.20106s" end="10.1922s"
>> smpte:backgroundImage="Subtitles_EN/SPU2.png" tts:origin="202px 50px"
>> tts:extent="302px 64px" >
>>
>>        <ittm:altText>This is a basic Example</ittm:altText>
>>
>>      </div>
>>
>>      <div begin="10.3032s" end="12.2943s"
>> smpte:backgroundImage="Subtitles_EN/SPU3.png" tts:origin="180px 402px"
>> tts:extent="341px 32px" >
>>
>>        <ittm:altText>of pop on style captioning with preformatted
>> background images</ittm:altText>
>>
>>      </div>
>>
>>    </div>
>>
>>  </body>
>>
>> </tt>
>>
>>
>>
>>
>>
>>
>>
>> Best regards,
>>
>>
>>
>> Simon Hailes.
>>
>> p.s. please reply direct if you have any comments/questions.  I don’t
>> monitor the mailing lists….
>>
>>
>>
>>
>> *Simon Hailes | Chief Technology Officer | Screen *Main Line : +44 1473
>> 831700 | Ext : 2161 |Mobile : +44 7802 759311 | Fax : +44 1473 830078
>> Simon.Hailes@screensystems.tv | www.screensystems.tv |
>> https://twitter.com/screensystems
>>
>>
>>
>> *Visit us at SMPTE Annual Technical Conference, Loews Hollywood Hotel,
>> Stand 107, October 21-23 Languages & the Media, Hotel Radission Blu,
>> Berlin, November 5-7 *
>>
>> *P** Before printing, think about the environment*
>>
>>
>>  This message may contain confidential and/or privileged information. If
>> you are not the intended recipient you must not use, copy, disclose or take
>> any action based on this message or any information herein. If you have
>> received this message in error, please advise the sender immediately by
>> reply e-mail and delete this message. Thank you for your cooperation.
>> Screen Subtitling Systems Ltd. Registered in England No. 2596832.
>> Registered Office: The Old Rectory, Claydon Church Lane, Claydon, Ipswich,
>> Suffolk, IP6 0EQ
>>    ­­
>>
>
>

Received on Wednesday, 8 October 2014 16:32:20 UTC