diff options
| author | Carl Hetherington <cth@carlh.net> | 2018-09-14 21:22:33 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2018-09-14 21:22:33 +0100 |
| commit | 234bca29f70aeeba4fffd67f987de876ff89b6cc (patch) | |
| tree | 1096d9356805a79d802e950438aef8267ff6df42 /src/lib/dcp_content.cc | |
| parent | 53c7f717da44c6ff681bde8946875e4f39764b25 (diff) | |
Basic and rather clumsy option to respect KDM validity windows.
Diffstat (limited to 'src/lib/dcp_content.cc')
| -rw-r--r-- | src/lib/dcp_content.cc | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/lib/dcp_content.cc b/src/lib/dcp_content.cc index a2874a604..3498cc961 100644 --- a/src/lib/dcp_content.cc +++ b/src/lib/dcp_content.cc @@ -657,3 +657,14 @@ DCPContent::set_cpl (string id) _cpl = id; } } + +bool +DCPContent::kdm_timing_window_valid () const +{ + if (!_kdm) { + return true; + } + + dcp::LocalTime now; + return _kdm->not_valid_before() < now && now < _kdm->not_valid_after(); +} |
