diff options
| author | Carl Hetherington <cth@carlh.net> | 2025-03-30 15:21:19 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2025-12-15 17:13:38 +0100 |
| commit | 5343c71130b0ee39b48b9fe8cb2eec59142a5d47 (patch) | |
| tree | 6dac656bc76dc1c4f47ae593e56f267d5c202a3e /src | |
| parent | 33c084b3f7e7eb633463304ee168a2c34ef45d10 (diff) | |
Use asset_id for INVALID_INTRINSIC_DURATION.
Diffstat (limited to 'src')
| -rw-r--r-- | src/verify.cc | 6 | ||||
| -rw-r--r-- | src/verify.h | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/verify.cc b/src/verify.cc index b4e697cd..e33eabce 100644 --- a/src/verify.cc +++ b/src/verify.cc @@ -1418,12 +1418,14 @@ verify_reel( map<Marker, Time>* markers_seen ) { + using VN = dcp::VerificationNote; + for (auto i: reel->assets()) { if (i->duration() && (i->duration().get() * i->edit_rate().denominator / i->edit_rate().numerator) < 1) { context.error(VerificationNote::Code::INVALID_DURATION, i->id()); } if ((i->intrinsic_duration() * i->edit_rate().denominator / i->edit_rate().numerator) < 1) { - context.error(VerificationNote::Code::INVALID_INTRINSIC_DURATION, i->id()); + context.add_note(VN(VN::Type::ERROR, VN::Code::INVALID_INTRINSIC_DURATION).set_asset_id(i->id())); } auto file_asset = dynamic_pointer_cast<ReelFileAsset>(i); if (i->encryptable() && !file_asset->hash()) { @@ -1978,7 +1980,7 @@ dcp::note_to_string(VerificationNote note, function<string (string)> process_str case VerificationNote::Code::MISSING_ASSETMAP: return process_string("No valid ASSETMAP or ASSETMAP.xml was found."); case VerificationNote::Code::INVALID_INTRINSIC_DURATION: - return compose("The intrinsic duration of the asset %1 is less than 1 second.", note.note().get()); + return compose("The intrinsic duration of the asset %1 is less than 1 second.", note.asset_id().get()); case VerificationNote::Code::INVALID_DURATION: return compose("The duration of the asset %1 is less than 1 second.", note.note().get()); case VerificationNote::Code::VALID_PICTURE_FRAME_SIZES_IN_BYTES: diff --git a/src/verify.h b/src/verify.h index 5430b188..08bfc773 100644 --- a/src/verify.h +++ b/src/verify.h @@ -155,7 +155,7 @@ public: /** No _ASSETMAP_ or _ASSETMAP.xml_ was found */ MISSING_ASSETMAP, /** An asset's _IntrinsicDuration_ is less than 1 second - * note contains asset ID + * asset_id contains asset ID */ INVALID_INTRINSIC_DURATION, /** An asset's _Duration_ is less than 1 second |
