Applies to: Protocol and format interpretation for developers inspecting authorized media delivery.
The useful distinctions
- TTML time expressions include clock-time and offset-time forms.
- A colon-separated frames term is distinct from fractional seconds.
- ttp:frameRate supplies a parameter used to interpret frame expressions.
Calculate the two representations
At the explicitly declared twenty-five frames per second, twelve frames represent twelve divided by twenty-five seconds, or 0.48 seconds. The first paragraph therefore starts at 1.48 seconds and ends at 2.48 seconds. The second paragraph uses offset seconds to express the same boundaries. They deliberately overlap completely as a comparison fixture; this is not intended as a production subtitle layout with duplicated text.
Retain the parameter context
Copying the frame-form paragraph into a document with a different frame rate changes its interpretation even though its attribute strings remain identical. Keep frame rate and time base in the import context, and distinguish a colon before frames from a decimal point before fractional seconds. A frame field value must also fit the declared nominal frame-rate bounds. The example uses media time and a simple integer rate, leaving frame-rate multipliers, subframes, and clock-time modes outside the exercise. For a real conversion, resolve those parameters before calculating decimal seconds and retain sufficient precision for a reversible result. A rounded display value in an editor should not become a newly asserted timing boundary unless that rounding is part of the export policy.
Worked example · synthetic
12/25 = 0.48, so both paragraphs occupy [1.48,2.48) seconds. The :12 field means twelve frames under the declared rate; it is not twelve hundredths of a second.
Synthetic text example; no network operation has been performed.
<tt xmlns="http://www.w3.org/ns/ttml"
xmlns:ttp="http://www.w3.org/ns/ttml#parameter"
xml:lang="en" ttp:timeBase="media" ttp:frameRate="25">
<body><div>
<p begin="00:00:01:12" end="00:00:02:12">Frame form.</p>
<p begin="1.48s" end="2.48s">Offset form.</p>
</div></body>
</tt>
Check the interpretation
- Resolve time base and frame-rate parameters first.
- Check frame fields against the declared rate.
- Keep rational arithmetic until the chosen export precision is applied.