diff options
| author | Carl Hetherington <cth@carlh.net> | 2021-03-15 01:36:51 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2021-03-15 01:36:51 +0100 |
| commit | 2c1faeb15715794525f48110c2b8a9df96b387c1 (patch) | |
| tree | c03b560ca0302d3d51fc0a9252f2574100e01f0b /src/dcp_time.h | |
| parent | f80f5f533ab09f64a022314380b2969b6ef88ec3 (diff) | |
Fix various bugs in subtitle/ccap verification.
Check that subtitles don't overlap reel boundaries, and fix a few
tests that trip this check.
Fix confusion when calculating subtitle timings during verification
where the picture asset frame rate was being used rather than the
subtitle asset's edit rate.
Do the subtitle timing verification for Interop as well as SMPTE
subtitles.
Take <StartTime> tags into account when checking subtitles, even
though Bv2.1 says they should be set to 0.
Rename Time::as_editable_units to Time::as_editable_units_ceil
and add a _floor variant, then use that to round down when checking
reel boundary overlaps.
Diffstat (limited to 'src/dcp_time.h')
| -rw-r--r-- | src/dcp_time.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/dcp_time.h b/src/dcp_time.h index dcbadf31..dbfdb7f0 100644 --- a/src/dcp_time.h +++ b/src/dcp_time.h @@ -127,10 +127,16 @@ public: double as_seconds () const; /** @param tcr_ Timecode rate with which the return value should be counted + * @return the total number of editable units that this time consists of at the specified timecode rate, rounded down + * to the nearest editable unit. For example, as_editable_units_floor(24) returns the total time in frames at 24fps. + */ + int64_t as_editable_units_floor (int tcr_) const; + + /** @param tcr_ Timecode rate with which the return value should be counted * @return the total number of editable units that this time consists of at the specified timecode rate, rounded up - * to the nearest editable unit. For example, as_editable_units (24) returns the total time in frames at 24fps. + * to the nearest editable unit. For example, as_editable_units_ceil(24) returns the total time in frames at 24fps. */ - int64_t as_editable_units (int tcr_) const; + int64_t as_editable_units_ceil (int tcr_) const; /** @param tcr_ New timecode rate * @return A new Time which is this time at the spcified new timecode rate |
