summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjhurst <jhurst@cinecert.com>2016-12-02 23:28:26 +0000
committerjhurst <>2016-12-02 23:28:26 +0000
commit779d581d1176e0d09ae13a65d8047509bfa11eeb (patch)
treea7c2fefe8a33c3a8b308ed85a7acbfc881018846
parent5f38f82f9bfc69fdbae47a71f587ab5b7e80e594 (diff)
o Fixed Partiton and Preface version numbers in AS-02 files
-rwxr-xr-xREADME17
-rw-r--r--src/AS_02_PHDR.cpp2
-rw-r--r--src/AS_02_internal.h2
-rw-r--r--src/AS_DCP_TimedText.cpp2
-rwxr-xr-xsrc/AS_DCP_internal.h28
-rwxr-xr-xsrc/h__Writer.cpp2
6 files changed, 43 insertions, 10 deletions
diff --git a/README b/README
index 54ce524..85f90e2 100755
--- a/README
+++ b/README
@@ -123,9 +123,9 @@ kmuuidgen, kmrandgen - generate UUID values and random numbers.
wavesplit - Splits a WAVE file into two or more output files. Used
to untangle incorrectly-paired DCDM sound files.
-blackwave - Write a WAVE file full of zeros, Used to make filler
- tracks (though you would be better off modifying asdcp-test if
- this is a common use case).
+blackwave - Write a WAVE file of zeros.
+
+pinkwave - Write a WAVE file of SMPTE ST 2095 pink noise.
j2c-test - Displays information about JP2K codestreams.
@@ -153,6 +153,17 @@ Change History
2016-12-01 - bug fixes 2.6.17
+ o Fixed Partiton and Preface version numbers in AS-02 files
+ o Replaced WIN32 directory scanner with dirent_win.h
+ o The NamespaceURI property of AS-02 timed text files has been exposed in the API
+ and via as-02-wrap -P. This behavior replaces previous bad behavior, but puts
+ responsibility for selecting the correct value on the operator.
+ o Exposed CreatePNGNameId and CreateFontNameId subroutines in AS_02::TimedText
+ o Adjusted UUID generation based on PNG and font names to exclude paths by
+ inserting a call to PathBasename at each Id generation site
+ o Fixed AS-02 timed text index partition
+ o Fixed contents of generic partiton EssenceContainers property in AS-DCP timed
+ text files
o Added PixelLayout to RGBAEssenceDescriptor (contributed by Schleich)
o Cleared up MXFGCP1FrameWrappedPictureElement / MXFGCP1FrameWrappedPictureElement
ambiguity. PHDR continues to use MXFGCP1FrameWrappedPictureElement.
diff --git a/src/AS_02_PHDR.cpp b/src/AS_02_PHDR.cpp
index 9322b31..d52618e 100644
--- a/src/AS_02_PHDR.cpp
+++ b/src/AS_02_PHDR.cpp
@@ -445,7 +445,7 @@ AS_02::PHDR::MXFWriter::h__Writer::WritePHDRHeader(const std::string& PackageLab
return RESULT_PARAM;
}
- InitHeader();
+ InitHeader(MXFVersion_2011);
AddSourceClip(EditRate, EditRate/*TODO: for a moment*/, TCFrameRate, TrackName, EssenceUL, DataDefinition, PackageLabel);
diff --git a/src/AS_02_internal.h b/src/AS_02_internal.h
index 76286b1..f67af68 100644
--- a/src/AS_02_internal.h
+++ b/src/AS_02_internal.h
@@ -172,7 +172,7 @@ namespace AS_02
return RESULT_PARAM;
}
- InitHeader();
+ InitHeader(MXFVersion_2011);
AddSourceClip(EditRate, EditRate/*TODO: for a moment*/, TCFrameRate, TrackName, EssenceUL, DataDefinition, PackageLabel);
AddEssenceDescriptor(WrappingUL);
diff --git a/src/AS_DCP_TimedText.cpp b/src/AS_DCP_TimedText.cpp
index af5e976..ab8dab9 100644
--- a/src/AS_DCP_TimedText.cpp
+++ b/src/AS_DCP_TimedText.cpp
@@ -580,7 +580,7 @@ ASDCP::TimedText::MXFWriter::h__Writer::SetSourceStream(ASDCP::TimedText::TimedT
if ( ASDCP_SUCCESS(result) )
{
- InitHeader();
+ InitHeader(MXFVersion_2004);
// First RIP Entry
if ( m_Info.LabelSetType == LS_MXF_SMPTE ) // ERK
diff --git a/src/AS_DCP_internal.h b/src/AS_DCP_internal.h
index c1df8ad..aaa9e60 100755
--- a/src/AS_DCP_internal.h
+++ b/src/AS_DCP_internal.h
@@ -1,5 +1,5 @@
/*
-Copyright (c) 2004-2013, John Hurst
+Copyright (c) 2004-2016, John Hurst
All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -122,6 +122,14 @@ namespace ASDCP
{ 0x43, 0x48, 0x55, 0x4b, 0x43, 0x48, 0x55, 0x4b,
0x43, 0x48, 0x55, 0x4b, 0x43, 0x48, 0x55, 0x4b };
+ // Version of MXF spec to which an MXF file conforms
+ enum MXFVersion
+ {
+ MXFVersion_2004,
+ MXFVersion_2011,
+ MXFVersion_MAX
+ };
+
//------------------------------------------------------------------------------------------
//
@@ -528,11 +536,11 @@ namespace ASDCP
const MXF::RIP& GetRIP() const { return m_RIP; }
- void InitHeader()
+ void InitHeader(const MXFVersion& mxf_ver)
{
assert(m_Dict);
assert(m_EssenceDescriptor);
-
+
m_HeaderPart.m_Primer.ClearTagList();
m_HeaderPart.m_Preface = new Preface(m_Dict);
m_HeaderPart.AddChildObject(m_HeaderPart.m_Preface);
@@ -542,6 +550,20 @@ namespace ASDCP
m_HeaderPart.m_Preface->OperationalPattern = UL(m_Dict->ul(MDD_OP1a));
m_HeaderPart.OperationalPattern = m_HeaderPart.m_Preface->OperationalPattern;
+ if ( mxf_ver == MXFVersion_2004 )
+ {
+ m_HeaderPart.MinorVersion = 2;
+ m_HeaderPart.m_Preface->Version = 258;
+ m_HeaderPart.m_Preface->ObjectModelVersion = 1;
+ }
+ else
+ {
+ assert(mxf_ver == MXFVersion_2011);
+ m_HeaderPart.MinorVersion = 3;
+ m_HeaderPart.m_Preface->Version = 259;
+ m_HeaderPart.m_Preface->ObjectModelVersion = 1;
+ }
+
// Identification
Identification* Ident = new Identification(m_Dict);
m_HeaderPart.AddChildObject(Ident);
diff --git a/src/h__Writer.cpp b/src/h__Writer.cpp
index 07d418f..93388cd 100755
--- a/src/h__Writer.cpp
+++ b/src/h__Writer.cpp
@@ -141,7 +141,7 @@ ASDCP::h__ASDCPWriter::WriteASDCPHeader(const std::string& PackageLabel, const U
const std::string& TrackName, const UL& EssenceUL, const UL& DataDefinition,
const MXF::Rational& EditRate, ui32_t TCFrameRate, ui32_t BytesPerEditUnit)
{
- InitHeader();
+ InitHeader(MXFVersion_2004);
// First RIP Entry
if ( m_Info.LabelSetType == LS_MXF_SMPTE ) // ERK