Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // variante #1
- double surplusChars = charPerSecond % maxCharPerSecond;
- double optimalMissingTime = surplusChars / maxCharPerSecond * TimeCode.BaseUnit;
- temp.EndTime.TotalMilliseconds += optimalMissingTime;
- // variante #2
- double msPerChar = 1 / maxCharPerSecond * TimeCode.BaseUnit;
- temp.EndTime.TotalMilliseconds += surplusChars * msPerChar;
- // variante #3
- temp.EndTime.TotalMilliseconds = temp.Text.Length / maxCharPerSecond * TimeCode.BaseUnit;
- see: https://github.com/SubtitleEdit/subtitleedit/pull/1694/files (not correct!)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement