From 63bff141f70aa81e50a7cf927e5110a2bb504ae6 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Sun, 6 Jan 2019 23:02:21 +0000 Subject: ClairMeta points out that SMPTE subtitle MXF's ResourceID should be the same as the internal XML ID. This in turn must be different from the MXF's UUID. I *think* that we have: AssetUUID: MXF's UUID, which must be different; written from the WriterInfo (set up by fill_writer_info, which is passed _id) AssetID: MXF's ResourceID, which must be the _xml_id; written from the TimedTextDescriptor. I believe that this patch fixes the ResourceID to be the XML ID (as required) without undoing the Doremi fix whereby the MXF UUID must be different to the XML ID. This patch quells ClairMeta's error. --- src/smpte_subtitle_asset.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/smpte_subtitle_asset.cc b/src/smpte_subtitle_asset.cc index 8408a57e..94b16d5b 100644 --- a/src/smpte_subtitle_asset.cc +++ b/src/smpte_subtitle_asset.cc @@ -357,7 +357,9 @@ SMPTESubtitleAsset::write (boost::filesystem::path p) const } descriptor.NamespaceName = "dcst"; - memcpy (descriptor.AssetID, writer_info.AssetUUID, ASDCP::UUIDlen); + unsigned int c; + Kumu::hex2bin (_xml_id.c_str(), descriptor.AssetID, ASDCP::UUIDlen, &c); + DCP_ASSERT (c == Kumu::UUID_Length); descriptor.ContainerDuration = _intrinsic_duration; ASDCP::TimedText::MXFWriter writer; -- cgit v1.2.3