summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2024-01-08 00:43:10 +0100
committerCarl Hetherington <cth@carlh.net>2024-04-15 10:59:34 +0200
commite274f96b55a535698224c0331025c67d31aa8f27 (patch)
tree7295c8f207b8c3a7be16760f0d01a7ac87963680 /src
parent0d31c86d6dfad9f437f5613d41cace9cc5928474 (diff)
Add OK note when <ContentKind> is valid.
Diffstat (limited to 'src')
-rw-r--r--src/verify.cc4
-rw-r--r--src/verify.h1
2 files changed, 5 insertions, 0 deletions
diff --git a/src/verify.cc b/src/verify.cc
index 17b751e6..e5959f23 100644
--- a/src/verify.cc
+++ b/src/verify.cc
@@ -1569,6 +1569,8 @@ verify_cpl(Context& context, shared_ptr<const CPL> cpl)
auto iter = std::find_if(all.begin(), all.end(), [name](ContentKind const& k) { return !k.scope() && k.name() == name; });
if (iter == all.end()) {
context.error(VerificationNote::Code::INVALID_CONTENT_KIND, cpl->content_kind().name());
+ } else {
+ context.ok(VerificationNote::Code::VALID_CONTENT_KIND, cpl->content_kind().name());
}
}
@@ -2155,6 +2157,8 @@ dcp::note_to_string (VerificationNote note)
return "There is an <Duration> node inside a <MainMarkers>.";
case VerificationNote::Code::INVALID_CONTENT_KIND:
return String::compose("<ContentKind> has an invalid value %1.", note.note().get());
+ case VerificationNote::Code::VALID_CONTENT_KIND:
+ return String::compose("Valid <ContentKind> %1.", note.note().get());
case VerificationNote::Code::INVALID_MAIN_PICTURE_ACTIVE_AREA:
return String::compose("<MainPictureActiveaArea> has an invalid value: %1", note.note().get());
case VerificationNote::Code::VALID_MAIN_PICTURE_ACTIVE_AREA:
diff --git a/src/verify.h b/src/verify.h
index df515d19..071a3e0c 100644
--- a/src/verify.h
+++ b/src/verify.h
@@ -420,6 +420,7 @@ public:
UNEXPECTED_DURATION,
/** A <ContentKind> has been specified with either no scope or the SMPTE 429-7 scope, but which is not one of those allowed */
INVALID_CONTENT_KIND,
+ VALID_CONTENT_KIND,
/** Either the width or height of a <MainPictureActiveArea> in a CPL is either not an even number, or bigger than the corresponding asset dimension.
* note contains details of what is wrong
* file contains the CPL filename