diff options
| author | Carl Hetherington <cth@carlh.net> | 2021-01-18 13:05:11 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2021-01-18 13:05:11 +0100 |
| commit | 36310b78f8fd84554f2c87dc513bd04efe0fd69a (patch) | |
| tree | 5586b8e6ecf890ee6a9887945a8c58e8ebea1e9d /src | |
| parent | bcc07ce5fce539b83fb2469073ed609c75ea9709 (diff) | |
Bv2.1 8.6.{1.2}: CompositionMetadataAsset must exist and it must have some <VersionNumber>.
Diffstat (limited to 'src')
| -rw-r--r-- | src/verify.cc | 13 | ||||
| -rw-r--r-- | src/verify.h | 4 |
2 files changed, 17 insertions, 0 deletions
diff --git a/src/verify.cc b/src/verify.cc index 1cea1a0c..d5b80b9f 100644 --- a/src/verify.cc +++ b/src/verify.cc @@ -1231,6 +1231,15 @@ dcp::verify ( if (result.error_length_exceeded) { notes.push_back (VerificationNote(VerificationNote::VERIFY_BV21_ERROR, VerificationNote::CLOSED_CAPTION_LINE_TOO_LONG)); } + + if (!cpl->full_content_title_text()) { + /* Since FullContentTitleText is assumed always to exist if there's a CompositionMetadataAsset we + * can use it as a proxy for CompositionMetadataAsset's existence. + */ + notes.push_back ({VerificationNote::VERIFY_BV21_ERROR, VerificationNote::MISSING_CPL_METADATA}); + } else if (!cpl->version_number()) { + notes.push_back ({VerificationNote::VERIFY_BV21_ERROR, VerificationNote::MISSING_CPL_METADATA_VERSION_NUMBER}); + } } } @@ -1364,6 +1373,10 @@ dcp::note_to_string (dcp::VerificationNote note) return "The FFOC marker should bet set to 1"; case dcp::VerificationNote::INCORRECT_LFOC: return "The LFOC marker should be set to 1 less than the duration of the last reel"; + case dcp::VerificationNote::MISSING_CPL_METADATA: + return "There should be a <CompositionMetadataAsset> tag"; + case dcp::VerificationNote::MISSING_CPL_METADATA_VERSION_NUMBER: + return "The CPL metadata must contain a <VersionNumber>"; } return ""; diff --git a/src/verify.h b/src/verify.h index 05a49417..65095a8f 100644 --- a/src/verify.h +++ b/src/verify.h @@ -165,6 +165,10 @@ public: INCORRECT_FFOC, /** The LFOC should be the last frame in the reel */ INCORRECT_LFOC, + /** There must be a <CompositionMetadataAsset> */ + MISSING_CPL_METADATA, + /** CPL metadata should contain <VersionNumber> of 1, at least */ + MISSING_CPL_METADATA_VERSION_NUMBER, }; VerificationNote (Type type, Code code) |
