- From: Charles Ritchea <CRitchea@nexidia.com>
- Date: Wed, 18 Jun 2014 14:06:47 +0000
- To: "public-tt@w3.org" <public-tt@w3.org>
- Message-ID: <42B3F8D37C0E4B49A7A083E76878008713EE1D@MBX029-E1-VA-6.EXCH029.DOMAIN.LOCAL>
There is an error in the below SMPTE Time algorithm: TTML Semantics - Time Expressions and SMPTE Time Relationship S = (countedFrames - droppedFrames + (subFrames / subFrameRate)) / effectiveFrameRate where countedFrames = (3600 * hours + 60 * minutes + seconds) * frameRate + frames hours, minutes, seconds, frames, subFrames components are extracted from time expression if present, or zero if not present; droppedFrames is computed as follows: 1. let dropMode be the computed value of the ttp:dropMode parameter; 2. if dropMode is dropNTSC, let droppedFrames = (hours * 54 + floor(minutes - minutes/10)) * 2; 3. otherwise, if dropMode is dropPAL, let droppedFrames = (hours * 27 + floor(minutes/2 - minutes/20)) * 4; 4. otherwise, let droppedFrames = 0; frameRate is the computed value of the ttp:frameRate parameter; subFrameRate is the computed value of the ttp:subFrameRate parameter; and effectiveFrameRate (in frames per second) is frameRate * frameRateMultipler where frameRate is the computed value of the ttp:frameRate parameter and frameRateMultipler is the computed value of the ttp:frameRateMultiplier parameter. Notwithstanding the above, if a time expression contains a frame code that is designated as dropped according to 6.2.3 ttp:dropMode<http://www.w3.org/TR/ttaf1-dfxp/#parameter-attribute-dropMode>, then that time expression should be considered to be invalid for purposes of validation assessment. 2. if dropMode is dropNTSC, let droppedFrames = (hours * 54 + floor(minutes - minutes/10)) * 2; should be: 2. if dropMode is dropNTSC, let droppedFrames = (hours * 54 + minutes - floor(minutes/10)) * 2; This can be clearly seen in the case of 00:01:00:03, which obviously has 2 frames dropped. In the original algorithm: floor(1 - 1/10)*2 -> floor(1 - 0.1)*2 -> floor(0..9)*2 -> 0*2 -> 0 In the modified algorithm: (1 - floor(1/10))*2 -> (1 -floor(0.1))*2 -> (1-0)*2 -> 1*2 -> 2 And I assume: 3. otherwise, if dropMode is dropPAL, let droppedFrames = (hours * 27 + floor(minutes/2 - minutes/20)) * 4; should be: 3. otherwise, if dropMode is dropPAL, let droppedFrames = (hours * 27 + floor(minutes/2) - floor(minutes/20)) * 4;
Received on Thursday, 19 June 2014 09:29:40 UTC