diff options
| author | jhurst <jhurst@cinecert.com> | 2012-02-02 01:58:43 +0000 |
|---|---|---|
| committer | jhurst <> | 2012-02-02 01:58:43 +0000 |
| commit | 99f3c9bd7e314ed2342598ad0e2357c68c79e732 (patch) | |
| tree | 09b3986d426dead4cbd63774db9ce1c5ac216a1e /src/AS_DCP_PCM.cpp | |
| parent | 1e0a44f949436b95b7def495dcaff9232dadf750 (diff) | |
make way for MCA
Diffstat (limited to 'src/AS_DCP_PCM.cpp')
| -rwxr-xr-x | src/AS_DCP_PCM.cpp | 53 |
1 files changed, 52 insertions, 1 deletions
diff --git a/src/AS_DCP_PCM.cpp b/src/AS_DCP_PCM.cpp index eb0c3b7..3956c71 100755 --- a/src/AS_DCP_PCM.cpp +++ b/src/AS_DCP_PCM.cpp @@ -1,5 +1,5 @@ /* -Copyright (c) 2004-2011, John Hurst +Copyright (c) 2004-2012, John Hurst All rights reserved. Redistribution and use in source and binary forms, with or without @@ -36,6 +36,10 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. //------------------------------------------------------------------------------------------ +static const ASDCP::Dictionary *sg_dict = &DefaultSMPTEDict(); +static MXF::OPAtomHeader sg_OPAtomHeader(sg_dict); +static MXF::OPAtomIndexFooter sg_OPAtomIndexFooter(sg_dict); + static std::string PCM_PACKAGE_LABEL = "File Package: SMPTE 382M frame wrapping of wave audio"; static std::string SOUND_DEF_LABEL = "Sound Track"; @@ -313,6 +317,30 @@ ASDCP::PCM::MXFReader::~MXFReader() m_Reader->Close(); } +// Warning: direct manipulation of MXF structures can interfere +// with the normal operation of the wrapper. Caveat emptor! +// +ASDCP::MXF::OPAtomHeader& +ASDCP::PCM::MXFReader::OPAtomHeader() +{ + if ( m_Reader.empty() ) + return sg_OPAtomHeader; + + return m_Reader->m_HeaderPart; +} + +// Warning: direct manipulation of MXF structures can interfere +// with the normal operation of the wrapper. Caveat emptor! +// +ASDCP::MXF::OPAtomIndexFooter& +ASDCP::PCM::MXFReader::OPAtomIndexFooter() +{ + if ( m_Reader.empty() ) + return sg_OPAtomIndexFooter; + + return m_Reader->m_FooterPart; +} + // Open the file for reading. The file must exist. Returns error if the // operation cannot be completed. ASDCP::Result_t @@ -544,6 +572,29 @@ ASDCP::PCM::MXFWriter::~MXFWriter() { } +// Warning: direct manipulation of MXF structures can interfere +// with the normal operation of the wrapper. Caveat emptor! +// +ASDCP::MXF::OPAtomHeader& +ASDCP::PCM::MXFWriter::OPAtomHeader() +{ + if ( m_Writer.empty() ) + return sg_OPAtomHeader; + + return m_Writer->m_HeaderPart; +} + +// Warning: direct manipulation of MXF structures can interfere +// with the normal operation of the wrapper. Caveat emptor! +// +ASDCP::MXF::OPAtomIndexFooter& +ASDCP::PCM::MXFWriter::OPAtomIndexFooter() +{ + if ( m_Writer.empty() ) + return sg_OPAtomIndexFooter; + + return m_Writer->m_FooterPart; +} // Open the file for writing. The file must not exist. Returns error if // the operation cannot be completed. |
