Compute the first frame# based on the first clip position
| 485 | |
| 486 | // Compute the first frame# based on the first clip position |
| 487 | int64_t Timeline::GetMinFrame() { |
| 488 | const double fps = info.fps.ToDouble(); |
| 489 | const double t = GetMinTime(); |
| 490 | // Inclusive start -> floor at the start boundary, then 1-index |
| 491 | return static_cast<int64_t>(std::floor(t * fps)) + 1; |
| 492 | } |
| 493 | |
| 494 | // Compute the start time of the first timeline clip |
| 495 | double Timeline::GetMinTime() { |