summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-07-01 12:22:38 +0100
committerCarl Hetherington <cth@carlh.net>2019-12-03 17:01:32 +0100
commitdfb6aa39a8000fc071dfa0680584dae173535c9a (patch)
treeccf64f8dbc81ab13d36f3319475fc0e59f95e2ec /src
parent8204f14304dd463a42f8540413cf95cf49e1f829 (diff)
Move public headers into src/asdcp and install them in a asdcp subdirectory.
Diffstat (limited to 'src')
-rwxr-xr-xsrc/AS_DCP_AES.cpp18
-rw-r--r--src/AS_DCP_ATMOS.cpp8
-rw-r--r--src/AS_DCP_DCData.cpp2
-rwxr-xr-xsrc/AS_DCP_MXF.cpp8
-rwxr-xr-xsrc/AS_DCP_internal.h4
-rwxr-xr-xsrc/JP2K.h10
-rwxr-xr-xsrc/JP2K_Codestream_Parser.cpp4
-rwxr-xr-xsrc/JP2K_Sequence_Parser.cpp4
-rwxr-xr-xsrc/KLV.h10
-rw-r--r--src/KM_fileio.cpp2
-rwxr-xr-xsrc/KM_log.cpp4
-rwxr-xr-xsrc/KM_log.h8
-rwxr-xr-xsrc/KM_mutex.h6
-rwxr-xr-xsrc/KM_prng.cpp4
-rw-r--r--src/KM_tai.cpp2
-rwxr-xr-xsrc/KM_util.cpp8
-rw-r--r--src/KM_xml.h2
-rwxr-xr-xsrc/MPEG.h8
-rwxr-xr-xsrc/MPEG2_Parser.cpp16
-rwxr-xr-xsrc/MXFTypes.cpp14
-rwxr-xr-xsrc/PCMParserList.cpp2
-rwxr-xr-xsrc/PCMParserList.h4
-rw-r--r--src/S12MTimecode.h6
-rwxr-xr-xsrc/Wav.h10
-rwxr-xr-xsrc/asdcp/AS_DCP.h (renamed from src/AS_DCP.h)4
-rwxr-xr-xsrc/asdcp/KM_error.h (renamed from src/KM_error.h)0
-rwxr-xr-xsrc/asdcp/KM_fileio.h (renamed from src/KM_fileio.h)2
-rwxr-xr-xsrc/asdcp/KM_memio.h (renamed from src/KM_memio.h)12
-rw-r--r--src/asdcp/KM_platform.h (renamed from src/KM_platform.h)0
-rwxr-xr-xsrc/asdcp/KM_prng.h (renamed from src/KM_prng.h)2
-rw-r--r--src/asdcp/KM_tai.h (renamed from src/KM_tai.h)4
-rwxr-xr-xsrc/asdcp/KM_util.h (renamed from src/KM_util.h)6
-rw-r--r--src/wscript47
33 files changed, 106 insertions, 135 deletions
diff --git a/src/AS_DCP_AES.cpp b/src/AS_DCP_AES.cpp
index 379e8ab..a320fb0 100755
--- a/src/AS_DCP_AES.cpp
+++ b/src/AS_DCP_AES.cpp
@@ -25,15 +25,15 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
/*! \file AS_DCP_AES.h
- \version $Id$
+ \version $Id$
\brief AS-DCP library, AES wrapper
*/
#include <assert.h>
-#include <AS_DCP.h>
+#include <asdcp/AS_DCP.h>
#include <KM_log.h>
-#include <KM_prng.h>
+#include <asdcp/KM_prng.h>
using Kumu::DefaultLogSink;
using namespace ASDCP;
@@ -142,8 +142,8 @@ ASDCP::AESEncContext::EncryptBlock(const byte_t* pt_buf, byte_t* ct_buf, ui32_t
{
// xor with the previous block
for ( ui32_t i = 0; i < CBC_BLOCK_SIZE; i++ )
- tmp_buf[i] = in_p[i] ^ Ctx->m_IVec[i];
-
+ tmp_buf[i] = in_p[i] ^ Ctx->m_IVec[i];
+
AES_encrypt(tmp_buf, Ctx->m_IVec, Ctx);
memcpy(out_p, Ctx->m_IVec, CBC_BLOCK_SIZE);
@@ -226,7 +226,7 @@ ASDCP::AESDecContext::DecryptBlock(const byte_t* ct_buf, byte_t* pt_buf, ui32_t
while ( block_size )
{
- AES_decrypt(in_p, out_p, Ctx);
+ AES_decrypt(in_p, out_p, Ctx);
for ( ui32_t i = 0; i < CBC_BLOCK_SIZE; i++ )
out_p[i] ^= Ctx->m_IVec[i];
@@ -276,7 +276,7 @@ public:
// MXF Interop MIC key generation
void SetInteropKey(const byte_t* key)
{
- static byte_t key_nonce[KeyLen] = { 0x00, 0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77,
+ static byte_t key_nonce[KeyLen] = { 0x00, 0x11, 0x22, 0x33, 0x44, 0x55, 0x66, 0x77,
0x88, 0x99, 0xaa, 0xbb, 0xcc, 0xdd, 0xee, 0xff };
byte_t sha_buf[SHA_DIGEST_LENGTH];
@@ -411,7 +411,7 @@ HMACContext::Finalize()
{
if ( m_Context.empty() || m_Context->m_Final )
return RESULT_INIT;
-
+
m_Context->Finalize();
return RESULT_OK;
}
@@ -439,7 +439,7 @@ HMACContext::TestHMACValue(const byte_t* buf) const
if ( m_Context.empty() || ! m_Context->m_Final )
return RESULT_INIT;
-
+
return ( memcmp(buf, m_Context->m_SHAValue, HMAC_SIZE) == 0 ) ? RESULT_OK : RESULT_HMACFAIL;
}
diff --git a/src/AS_DCP_ATMOS.cpp b/src/AS_DCP_ATMOS.cpp
index 7fa8c09..2be8959 100644
--- a/src/AS_DCP_ATMOS.cpp
+++ b/src/AS_DCP_ATMOS.cpp
@@ -32,7 +32,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <iostream>
-#include "AS_DCP.h"
+#include <asdcp/AS_DCP.h>
#include "AS_DCP_DCData_internal.h"
#include "AS_DCP_internal.h"
@@ -148,13 +148,13 @@ ASDCP::ATMOS::MXFReader::h__Reader::OpenRead(const std::string& filename)
if( ASDCP_SUCCESS(result) )
{
-
+
if (NULL == m_EssenceSubDescriptor)
{
InterchangeObject* iObj = NULL;
result = m_HeaderPart.GetMDObjectByType(OBJ_TYPE_ARGS(DolbyAtmosSubDescriptor), &iObj);
m_EssenceSubDescriptor = static_cast<MXF::DolbyAtmosSubDescriptor*>(iObj);
-
+
if ( iObj == 0 )
{
DefaultLogSink().Error("DolbyAtmosSubDescriptor object not found.\n");
@@ -487,5 +487,3 @@ ASDCP::ATMOS::MXFWriter::Finalize()
//
// end AS_DCP_ATMOS.cpp
//
-
-
diff --git a/src/AS_DCP_DCData.cpp b/src/AS_DCP_DCData.cpp
index e145e1f..7c98fea 100644
--- a/src/AS_DCP_DCData.cpp
+++ b/src/AS_DCP_DCData.cpp
@@ -31,7 +31,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <iostream>
-#include "AS_DCP.h"
+#include <asdcp/AS_DCP.h>
#include "AS_DCP_DCData_internal.h"
#include "AS_DCP_internal.h"
diff --git a/src/AS_DCP_MXF.cpp b/src/AS_DCP_MXF.cpp
index 32225be..e5d9a91 100755
--- a/src/AS_DCP_MXF.cpp
+++ b/src/AS_DCP_MXF.cpp
@@ -29,7 +29,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief AS-DCP library, misc classes and subroutines
*/
-#include <KM_fileio.h>
+#include <asdcp/KM_fileio.h>
#include <KM_xml.h>
#include "AS_DCP_internal.h"
#include "JP2K.h"
@@ -331,7 +331,7 @@ ASDCP::RawEssenceType(const std::string& filename, EssenceType_t& type)
else
{
result = RF64Header.ReadFromBuffer(FB.RoData(), read_count, &data_offset);
-
+
if ( ASDCP_SUCCESS(result) )
{
switch ( RF64Header.samplespersec )
@@ -415,7 +415,7 @@ ASDCP::RawEssenceType(const std::string& filename, EssenceType_t& type)
type = ESS_DCDATA_UNKNOWN;
}
}
-
+
break;
}
}
@@ -625,7 +625,7 @@ ASDCP::IntegrityPack::TestValues(const ASDCP::FrameBuffer& FB, const byte_t* Ass
return RESULT_HMACFAIL;
}
p += UUIDlen;
-
+
// test the sequence length
if ( ! Kumu::read_test_BER(&p, sizeof(ui64_t)) )
return RESULT_HMACFAIL;
diff --git a/src/AS_DCP_internal.h b/src/AS_DCP_internal.h
index 782e5c4..d759d1c 100755
--- a/src/AS_DCP_internal.h
+++ b/src/AS_DCP_internal.h
@@ -32,8 +32,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _AS_DCP_INTERNAL_H_
#define _AS_DCP_INTERNAL_H_
-#include <KM_platform.h>
-#include <KM_util.h>
+#include <asdcp/KM_platform.h>
+#include <asdcp/KM_util.h>
#include <KM_log.h>
#include "Metadata.h"
diff --git a/src/JP2K.h b/src/JP2K.h
index b043dfc..5128025 100755
--- a/src/JP2K.h
+++ b/src/JP2K.h
@@ -36,9 +36,9 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#define _JP2K_H_
// AS_DCP.h is included only for it's base type definitions.
-#include <KM_platform.h>
-#include <KM_util.h>
-#include <AS_DCP.h>
+#include <asdcp/KM_platform.h>
+#include <asdcp/KM_util.h>
+#include <asdcp/AS_DCP.h>
#include <assert.h>
namespace ASDCP
@@ -146,7 +146,7 @@ namespace JP2K
}
~COD() {}
-
+
inline ui8_t ProgOrder() const { return *(m_MarkerData + SGcodOFST ); }
inline ui16_t Layers() const { return KM_i16_BE(*(ui16_t*)(m_MarkerData + SGcodOFST + 1));}
inline ui8_t DecompLevels() const { return *(m_MarkerData + SPcodOFST); }
@@ -213,7 +213,7 @@ namespace JP2K
}
~COM() {}
-
+
inline bool IsText() const { return m_IsText; }
inline const byte_t* CommentData() const { return m_MarkerData; }
inline ui32_t CommentSize() const { return m_DataSize; }
diff --git a/src/JP2K_Codestream_Parser.cpp b/src/JP2K_Codestream_Parser.cpp
index 99bf836..3213f30 100755
--- a/src/JP2K_Codestream_Parser.cpp
+++ b/src/JP2K_Codestream_Parser.cpp
@@ -29,8 +29,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief AS-DCP library, JPEG 2000 codestream essence reader implementation
*/
-#include <KM_fileio.h>
-#include <AS_DCP.h>
+#include <asdcp/KM_fileio.h>
+#include <asdcp/AS_DCP.h>
#include <JP2K.h>
#include <assert.h>
#include <KM_log.h>
diff --git a/src/JP2K_Sequence_Parser.cpp b/src/JP2K_Sequence_Parser.cpp
index caf9d2d..dcdea85 100755
--- a/src/JP2K_Sequence_Parser.cpp
+++ b/src/JP2K_Sequence_Parser.cpp
@@ -29,8 +29,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief AS-DCP library, JPEG 2000 codestream essence reader implementation
*/
-#include <AS_DCP.h>
-#include <KM_fileio.h>
+#include <asdcp/AS_DCP.h>
+#include <asdcp/KM_fileio.h>
#include <KM_log.h>
#include <list>
#include <string>
diff --git a/src/KLV.h b/src/KLV.h
index b49cd07..0f867d8 100755
--- a/src/KLV.h
+++ b/src/KLV.h
@@ -32,9 +32,9 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KLV_H_
#define _KLV_H_
-#include <KM_fileio.h>
-#include <KM_memio.h>
-#include "AS_DCP.h"
+#include <asdcp/KM_fileio.h>
+#include <asdcp/KM_memio.h>
+#include <asdcp/AS_DCP.h>
#include "MDD.h"
#include <map>
@@ -55,7 +55,7 @@ namespace ASDCP
const ui32_t IntBufferLen = 64;
inline const char* i64sz(i64_t i, char* buf)
-{
+{
assert(buf);
#ifdef WIN32
snprintf(buf, IntBufferLen, "%I64d", i);
@@ -66,7 +66,7 @@ inline const char* i64sz(i64_t i, char* buf)
}
inline const char* ui64sz(ui64_t i, char* buf)
-{
+{
assert(buf);
#ifdef WIN32
snprintf(buf, IntBufferLen, "%I64u", i);
diff --git a/src/KM_fileio.cpp b/src/KM_fileio.cpp
index 60c50a0..d75af2c 100644
--- a/src/KM_fileio.cpp
+++ b/src/KM_fileio.cpp
@@ -29,7 +29,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief portable file i/o
*/
-#include <KM_fileio.h>
+#include <asdcp/KM_fileio.h>
#include <KM_log.h>
#include <fcntl.h>
#include <sstream>
diff --git a/src/KM_log.cpp b/src/KM_log.cpp
index 885dd12..2ebd058 100755
--- a/src/KM_log.cpp
+++ b/src/KM_log.cpp
@@ -29,7 +29,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief message logging API
*/
-#include <KM_util.h>
+#include <asdcp/KM_util.h>
#include <KM_log.h>
#include <KM_mutex.h>
#include <sys/types.h>
@@ -328,7 +328,7 @@ Kumu::LogEntry::CreateStringWithOptions(std::string& out_buf, i32_t opt) const
if ( (opt & LOG_OPTION_TYPE) != 0 )
{
if ( ! out_buf.empty() ) out_buf += " ";
-
+
switch ( Type )
{
case LOG_CRIT: out_buf += "CRT"; break;
diff --git a/src/KM_log.h b/src/KM_log.h
index 9279f30..c604fc5 100755
--- a/src/KM_log.h
+++ b/src/KM_log.h
@@ -33,9 +33,9 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_LOG_H_
#define _KM_LOG_H_
-#include <KM_platform.h>
+#include <asdcp/KM_platform.h>
#include <KM_mutex.h>
-#include <KM_util.h>
+#include <asdcp/KM_util.h>
#include <stdarg.h>
#include <errno.h>
#include <iosfwd>
@@ -144,7 +144,7 @@ namespace Kumu
typedef ArchivableList<LogEntry> LogEntryList;
-
+
//
class ILogSink
{
@@ -306,7 +306,7 @@ namespace Kumu
{
KM_NO_COPY_CONSTRUCT(SyslogLogSink);
SyslogLogSink();
-
+
public:
SyslogLogSink(const std::string& source_name, int facility);
virtual ~SyslogLogSink();
diff --git a/src/KM_mutex.h b/src/KM_mutex.h
index fa13085..b44c4f2 100755
--- a/src/KM_mutex.h
+++ b/src/KM_mutex.h
@@ -32,7 +32,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_MUTEX_H_
#define _KM_MUTEX_H_
-#include <KM_platform.h>
+#include <asdcp/KM_platform.h>
#ifndef KM_WIN32
# include <pthread.h>
@@ -57,7 +57,7 @@ namespace Kumu
{
pthread_mutex_t m_Mutex;
KM_NO_COPY_CONSTRUCT(Mutex);
-
+
public:
inline Mutex() { pthread_mutex_init(&m_Mutex, 0); }
inline ~Mutex() { pthread_mutex_destroy(&m_Mutex); }
@@ -66,7 +66,7 @@ namespace Kumu
};
#endif // KM_WIN32
- // automatic Mutex management within a block -
+ // automatic Mutex management within a block -
// the mutex is created by the constructor and
// released by the destructor
class AutoMutex
diff --git a/src/KM_prng.cpp b/src/KM_prng.cpp
index 31ae93e..181c563 100755
--- a/src/KM_prng.cpp
+++ b/src/KM_prng.cpp
@@ -29,7 +29,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief Fortuna pseudo-random number generator
*/
-#include <KM_prng.h>
+#include <asdcp/KM_prng.h>
#include <KM_log.h>
#include <KM_mutex.h>
#include <string.h>
@@ -44,7 +44,7 @@ using namespace Kumu;
#ifdef KM_WIN32
# include <wincrypt.h>
#else // KM_WIN32
-# include <KM_fileio.h>
+# include <asdcp/KM_fileio.h>
const char* DEV_URANDOM = "/dev/urandom";
#endif // KM_WIN32
diff --git a/src/KM_tai.cpp b/src/KM_tai.cpp
index 00a1231..16fd5d3 100644
--- a/src/KM_tai.cpp
+++ b/src/KM_tai.cpp
@@ -48,7 +48,7 @@ The libtai source code is in the public domain.
\brief portable time functions
*/
-#include <KM_tai.h>
+#include <asdcp/KM_tai.h>
#ifdef KM_WIN32
#include <time.h>
#else
diff --git a/src/KM_util.cpp b/src/KM_util.cpp
index 674c984..5409eae 100755
--- a/src/KM_util.cpp
+++ b/src/KM_util.cpp
@@ -29,10 +29,10 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief Utility functions
*/
-#include <KM_util.h>
-#include <KM_prng.h>
-#include <KM_memio.h>
-#include <KM_fileio.h>
+#include <asdcp/KM_util.h>
+#include <asdcp/KM_prng.h>
+#include <asdcp/KM_memio.h>
+#include <asdcp/KM_fileio.h>
#include <KM_log.h>
#include <KM_mutex.h>
#include <ctype.h>
diff --git a/src/KM_xml.h b/src/KM_xml.h
index 0c84e56..889811f 100644
--- a/src/KM_xml.h
+++ b/src/KM_xml.h
@@ -33,7 +33,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_XML_H_
#define _KM_XML_H_
-#include <KM_util.h>
+#include <asdcp/KM_util.h>
#include <list>
#include <string>
diff --git a/src/MPEG.h b/src/MPEG.h
index 6833584..c0adcfb 100755
--- a/src/MPEG.h
+++ b/src/MPEG.h
@@ -32,8 +32,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _MPEG_H_
#define _MPEG_H_
-#include <KM_platform.h>
-#include "AS_DCP.h"
+#include <asdcp/KM_platform.h>
+#include <asdcp/AS_DCP.h>
#include <stdio.h>
#include <assert.h>
@@ -219,7 +219,7 @@ namespace ASDCP
{
const byte_t* m_p;
ASDCP_NO_COPY_CONSTRUCT(Picture);
-
+
public:
Picture(const byte_t* p) { assert(p); m_p = p + 4; }
inline i16_t TemporalRef() {
@@ -230,7 +230,7 @@ namespace ASDCP
return (FrameType_t)( ( m_p[1] & 0x38 ) >> 3 );
}
};
-
+
} // namespace Accessor
} // namespace MPEG2
diff --git a/src/MPEG2_Parser.cpp b/src/MPEG2_Parser.cpp
index eee4635..59a6f3e 100755
--- a/src/MPEG2_Parser.cpp
+++ b/src/MPEG2_Parser.cpp
@@ -29,7 +29,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief AS-DCP library, MPEG2 raw essence reader implementation
*/
-#include <KM_fileio.h>
+#include <asdcp/KM_fileio.h>
#include <MPEG.h>
#include <KM_log.h>
@@ -97,7 +97,7 @@ class h__ParserState
default:
break;
}
-
+
DefaultLogSink().Error("SEQ follows %s\n", StringParserState(m_State));
return RESULT_STATE;
}
@@ -115,7 +115,7 @@ class h__ParserState
default:
break;
}
-
+
DefaultLogSink().Error("Slice follows %s\n", StringParserState(m_State));
return RESULT_STATE;
}
@@ -135,7 +135,7 @@ class h__ParserState
default:
break;
}
-
+
DefaultLogSink().Error("PIC follows %s\n", StringParserState(m_State));
return RESULT_STATE;
}
@@ -153,7 +153,7 @@ class h__ParserState
default:
break;
}
-
+
DefaultLogSink().Error("GOP follows %s\n", StringParserState(m_State));
return RESULT_STATE;
}
@@ -284,7 +284,7 @@ public:
}
~FrameParser() {}
-
+
void Reset()
{
m_FrameSize = 0;
@@ -414,10 +414,10 @@ ASDCP::MPEG2::Parser::h__Parser::OpenRead(const std::string& filename)
ui32_t read_count = 0;
Result_t result = m_FileReader.OpenRead(filename);
-
+
if ( ASDCP_SUCCESS(result) )
result = m_FileReader.Read(m_TmpBuffer.Data(), m_TmpBuffer.Capacity(), &read_count);
-
+
if ( ASDCP_SUCCESS(result) )
{
const byte_t* p = m_TmpBuffer.RoData();
diff --git a/src/MXFTypes.cpp b/src/MXFTypes.cpp
index c25386e..b7d4c4a 100755
--- a/src/MXFTypes.cpp
+++ b/src/MXFTypes.cpp
@@ -29,8 +29,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\brief MXF objects
*/
-#include <KM_prng.h>
-#include <KM_tai.h>
+#include <asdcp/KM_prng.h>
+#include <asdcp/KM_tai.h>
#include "MXFTypes.h"
#include <KM_log.h>
@@ -173,7 +173,7 @@ ASDCP::UMID::MakeUMID(int Type, const UUID& AssetID)
// Instance Number
m_Value[13] = m_Value[14] = m_Value[15] = 0;
-
+
memcpy(&m_Value[16], AssetID.Value(), AssetID.Size());
m_HasValue = true;
}
@@ -250,7 +250,7 @@ ASDCP::MXF::UTF16String::operator=(const char* sz)
else
this->assign(sz);
-
+
return *this;
}
@@ -372,7 +372,7 @@ ASDCP::MXF::ISO8String::operator=(const char* sz)
else
this->assign(sz);
-
+
return *this;
}
@@ -452,7 +452,7 @@ ASDCP::MXF::TLVReader::FindTL(const MDDEntry& Entry)
DefaultLogSink().Error("No Lookup service\n");
return false;
}
-
+
TagValue TmpTag;
if ( m_Lookup->TagForKey(Entry.ul, TmpTag) != RESULT_OK )
@@ -617,7 +617,7 @@ ASDCP::MXF::TLVWriter::WriteUi8(const MDDEntry& Entry, ui8_t* value)
if ( ! MemIOWriter::WriteUi16BE(sizeof(ui8_t)) ) return RESULT_KLV_CODING(__LINE__, __FILE__);
if ( ! MemIOWriter::WriteUi8(*value) ) return RESULT_KLV_CODING(__LINE__, __FILE__);
}
-
+
return result;
}
diff --git a/src/PCMParserList.cpp b/src/PCMParserList.cpp
index 0ae22cc..f65aae6 100755
--- a/src/PCMParserList.cpp
+++ b/src/PCMParserList.cpp
@@ -30,7 +30,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#include <PCMParserList.h>
-#include <KM_fileio.h>
+#include <asdcp/KM_fileio.h>
#include <KM_log.h>
#include <assert.h>
diff --git a/src/PCMParserList.h b/src/PCMParserList.h
index dbacd68..72bad1b 100755
--- a/src/PCMParserList.h
+++ b/src/PCMParserList.h
@@ -32,8 +32,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _PCMPARSERLIST_H_
#define _PCMPARSERLIST_H_
-#include <KM_fileio.h>
-#include <AS_DCP.h>
+#include <asdcp/KM_fileio.h>
+#include <asdcp/AS_DCP.h>
#include <vector>
namespace ASDCP
diff --git a/src/S12MTimecode.h b/src/S12MTimecode.h
index 6abe3f6..7358dad 100644
--- a/src/S12MTimecode.h
+++ b/src/S12MTimecode.h
@@ -25,7 +25,7 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
/*! \file S12MTimecode.cpp
- \version $Id$
+ \version $Id$
\brief AS-DCP library, Timecode PCM essence reader and writer implementation
*/
@@ -38,8 +38,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _S12MTIMECODE_H_
#define _S12MTIMECODE_H_
-#include "KM_util.h"
-#include "KM_memio.h"
+#include <asdcp/KM_util.h>
+#include <asdcp/KM_memio.h>
namespace ASDCP {
diff --git a/src/Wav.h b/src/Wav.h
index 7e274d8..1a433ca 100755
--- a/src/Wav.h
+++ b/src/Wav.h
@@ -32,8 +32,8 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _WAV_H_
#define _WAV_H_
-#include <KM_fileio.h>
-#include <AS_DCP.h>
+#include <asdcp/KM_fileio.h>
+#include <asdcp/AS_DCP.h>
namespace ASDCP
{
@@ -72,7 +72,7 @@ namespace ASDCP
numChannels(0), numSampleFrames(0), sampleSize(0), data_len(0) {
memset(sampleRate, 0, 10);
}
-
+
Result_t ReadFromBuffer(const byte_t* buf, ui32_t buf_len, ui32_t* data_start);
Result_t ReadFromFile(const Kumu::FileReader& InFile, ui32_t* data_start);
void FillADesc(ASDCP::PCM::AudioDescriptor& ADesc, Rational PictureRate) const;
@@ -108,9 +108,9 @@ namespace ASDCP
SimpleWaveHeader() :
format(0), nchannels(0), samplespersec(0), avgbps(0),
blockalign(0), bitspersample(0), cbsize(0), data_len(0) {}
-
+
SimpleWaveHeader(ASDCP::PCM::AudioDescriptor& ADesc);
-
+
Result_t ReadFromBuffer(const byte_t* buf, ui32_t buf_len, ui32_t* data_start);
Result_t ReadFromFile(const Kumu::FileReader& InFile, ui32_t* data_start);
Result_t WriteToFile(Kumu::FileWriter& OutFile) const;
diff --git a/src/AS_DCP.h b/src/asdcp/AS_DCP.h
index 24bd176..72b847e 100755
--- a/src/AS_DCP.h
+++ b/src/asdcp/AS_DCP.h
@@ -84,8 +84,8 @@ This project depends upon the following libraries:
#ifndef _AS_DCP_H_
#define _AS_DCP_H_
-#include <KM_error.h>
-#include <KM_fileio.h>
+#include <asdcp/KM_error.h>
+#include <asdcp/KM_fileio.h>
#include <stdio.h>
#include <stdarg.h>
#include <math.h>
diff --git a/src/KM_error.h b/src/asdcp/KM_error.h
index 8270cc0..8270cc0 100755
--- a/src/KM_error.h
+++ b/src/asdcp/KM_error.h
diff --git a/src/KM_fileio.h b/src/asdcp/KM_fileio.h
index 527373e..1fab636 100755
--- a/src/KM_fileio.h
+++ b/src/asdcp/KM_fileio.h
@@ -32,7 +32,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_FILEIO_H_
#define _KM_FILEIO_H_
-#include <KM_util.h>
+#include <asdcp/KM_util.h>
#include <string>
#include <boost/filesystem.hpp>
#include <openssl/md5.h>
diff --git a/src/KM_memio.h b/src/asdcp/KM_memio.h
index caf4fc0..557b868 100755
--- a/src/KM_memio.h
+++ b/src/asdcp/KM_memio.h
@@ -32,7 +32,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_MEMIO_H_
#define _KM_MEMIO_H_
-#include <KM_platform.h>
+#include <asdcp/KM_platform.h>
#include <string>
#include <cstring>
@@ -45,7 +45,7 @@ namespace Kumu
{
KM_NO_COPY_CONSTRUCT(MemIOWriter);
MemIOWriter();
-
+
protected:
byte_t* m_p;
ui32_t m_capacity;
@@ -98,7 +98,7 @@ namespace Kumu
inline bool WriteUi16BE(ui16_t i) {
if ( ( m_size + sizeof(ui16_t) ) > m_capacity )
return false;
-
+
i2p<ui16_t>(KM_i16_BE(i), m_p + m_size);
m_size += sizeof(ui16_t);
return true;
@@ -107,7 +107,7 @@ namespace Kumu
inline bool WriteUi32BE(ui32_t i) {
if ( ( m_size + sizeof(ui32_t) ) > m_capacity )
return false;
-
+
i2p<ui32_t>(KM_i32_BE(i), m_p + m_size);
m_size += sizeof(ui32_t);
return true;
@@ -116,7 +116,7 @@ namespace Kumu
inline bool WriteUi64BE(ui64_t i) {
if ( ( m_size + sizeof(ui64_t) ) > m_capacity )
return false;
-
+
i2p<ui64_t>(KM_i64_BE(i), m_p + m_size);
m_size += sizeof(ui64_t);
return true;
@@ -135,7 +135,7 @@ namespace Kumu
{
KM_NO_COPY_CONSTRUCT(MemIOReader);
MemIOReader();
-
+
protected:
const byte_t* m_p;
ui32_t m_capacity;
diff --git a/src/KM_platform.h b/src/asdcp/KM_platform.h
index defcd8a..defcd8a 100644
--- a/src/KM_platform.h
+++ b/src/asdcp/KM_platform.h
diff --git a/src/KM_prng.h b/src/asdcp/KM_prng.h
index f4497ed..e2bc3f1 100755
--- a/src/KM_prng.h
+++ b/src/asdcp/KM_prng.h
@@ -32,7 +32,7 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_PRNG_H_
#define _KM_PRNG_H_
-#include <KM_util.h>
+#include <asdcp/KM_util.h>
namespace Kumu
{
diff --git a/src/KM_tai.h b/src/asdcp/KM_tai.h
index da90df7..a126760 100644
--- a/src/KM_tai.h
+++ b/src/asdcp/KM_tai.h
@@ -51,7 +51,7 @@ The libtai source code is in the public domain.
#ifndef _KUMU_TAI_H_
#define _KUMU_TAI_H_
-#include <KM_platform.h>
+#include <asdcp/KM_platform.h>
//
namespace Kumu
@@ -72,7 +72,7 @@ namespace Kumu
const tai& operator=(const caltime& rhs);
};
-
+
//
struct caldate
{
diff --git a/src/KM_util.h b/src/asdcp/KM_util.h
index fc1330f..409d66e 100755
--- a/src/KM_util.h
+++ b/src/asdcp/KM_util.h
@@ -32,9 +32,9 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef _KM_UTIL_H_
#define _KM_UTIL_H_
-#include <KM_memio.h>
-#include <KM_error.h>
-#include <KM_tai.h>
+#include <asdcp/KM_memio.h>
+#include <asdcp/KM_error.h>
+#include <asdcp/KM_tai.h>
#include <string.h>
#include <list>
diff --git a/src/wscript b/src/wscript
index 6b0f037..63ad311 100644
--- a/src/wscript
+++ b/src/wscript
@@ -80,44 +80,17 @@ def build(bld):
"""
headers = """
- KM_xml.h
- KM_error.h
- SyncEncoder.h
- ST2095_PinkNoise.h
- MXF.h
- Wav.h
- Metadata.h
- KM_mutex.h
- JP2K.h
- AtmosSyncChannel_Mixer.h
- AtmosSyncChannel_Generator.h
- SyncCommon.h
- AS_02.h
- AS_02_internal.h
- KM_tai.h
- KLV.h
- PCMParserList.h
- AS_DCP_internal.h
- KM_log.h
- AS_02_PHDR.h
- UUIDInformation.h
- KM_memio.h
- KM_prng.h
- KM_fileio.h
- MXFTypes.h
- AS_DCP.h
- KM_util.h
- AS_DCP_DCData_internal.h
- MDD.h
- MPEG.h
- WavFileWriter.h
- S12MTimecode.h
- KM_platform.h
- PCMDataProviders.h
- CRC16.h
- """
+ asdcp/KM_util.h
+ asdcp/KM_memio.h
+ asdcp/KM_platform.h
+ asdcp/KM_error.h
+ asdcp/KM_tai.h
+ asdcp/KM_fileio.h
+ asdcp/KM_prng.h
+ asdcp/AS_DCP.h
+ """
- bld.install_files('${PREFIX}/include/libasdcp-cth', headers)
+ bld.install_files('${PREFIX}/include/libasdcp-cth/asdcp', headers)
if bld.env.STATIC:
bld.install_files('${PREFIX}/lib', 'libkumu-cth.a')
bld.install_files('${PREFIX}/lib', 'libasdcp-cth.a')