(timeline: Timeline, fraction: number)
| 159 | |
| 160 | /** Die Zeit an dieser Stelle des Strahls. `fraction` liegt zwischen 0 und 1. */ |
| 161 | export function timeAtFraction(timeline: Timeline, fraction: number): number { |
| 162 | const clamped = fraction <= 0 ? 0 : fraction >= 1 ? 1 : fraction; |
| 163 | return Math.round(timeline.from + clamped * timeline.windowMs); |
| 164 | } |
no outgoing calls
no test coverage detected