eliminate output filename warnings
authormsheby <msheby@cinecert.com>
Sun, 1 Apr 2012 21:24:45 +0000 (21:24 +0000)
committermsheby <>
Sun, 1 Apr 2012 21:24:45 +0000 (21:24 +0000)
configure.ac
src/AS_02.h
src/MXF.cpp
src/Makefile.am
src/h__02_Writer.cpp

index bc3b84e872c01a901be7d92256f43bc05c21075f..e3261a46312a2dbfcf1b47f6a43782e5bd2b6013 100644 (file)
@@ -37,7 +37,7 @@ AC_PREREQ([2.59])
 # For example, if asdcplib version 1.0.0 were modified to accomodate changes
 # in file format, and if no changes were made to AS_DCP.h, the new version would be
 # 1.0.1. If changes were also required in AS_DCP.h, the new version would be 1.1.1.
-AC_INIT([asdcplib], [1.9.45], [asdcplib@cinecert.com])
+AC_INIT([asdcplib], [1.9.45a], [asdcplib@cinecert.com])
 
 AC_CONFIG_AUX_DIR([build-aux])
 AC_CONFIG_SRCDIR([src/KM_error.h])
index 355f93a82c3c9e2f3787f239042c592d099fe5c3..caad97af051a975b6ba067b2a59fc13cca9ad77c 100644 (file)
@@ -58,9 +58,8 @@ The following use cases are supported by the module:
 
 namespace ASDCP {
   namespace MXF {
-    // #include<Metadata.h> to use these
+    // #include<Metadata.h> to use this
     class OPAtomHeader;
-    class OPAtomIndexFooter;
   };
 };
 
index 6bc3fcb86f9eecfdf6116ed616e8f3bbbd21c502..7f042eebfee95fc298578589af04eb0f6db79390 100755 (executable)
@@ -57,7 +57,10 @@ ASDCP::MXF::SeekToRIP(const Kumu::FileReader& Reader)
 
   if ( ASDCP_SUCCESS(result)
        && end_pos < (SMPTE_UL_LENGTH+MXF_BER_LENGTH) )
-    result = RESULT_FAIL;  // File is smaller than an empty packet!
+    {
+      DefaultLogSink().Error("File is smaller than an KLV empty packet.\n");
+      result = RESULT_FAIL;
+    }
 
   if ( ASDCP_SUCCESS(result) )
     result = Reader.Seek(end_pos - 4);
@@ -72,7 +75,10 @@ ASDCP::MXF::SeekToRIP(const Kumu::FileReader& Reader)
       result = Reader.Read(intbuf, MXF_BER_LENGTH, &read_count);
 
       if ( ASDCP_SUCCESS(result) && read_count != 4 )
-       result = RESULT_FAIL;
+       {
+         DefaultLogSink().Error("RIP contains fewer than four bytes.\n");
+         result = RESULT_FAIL;
+       }
     }
 
   if ( ASDCP_SUCCESS(result) )
@@ -80,7 +86,10 @@ ASDCP::MXF::SeekToRIP(const Kumu::FileReader& Reader)
       rip_size = KM_i32_BE(Kumu::cp2i<ui32_t>(intbuf));
 
       if ( rip_size > end_pos ) // RIP can't be bigger than the file
-       return RESULT_FAIL;
+       {
+         DefaultLogSink().Error("RIP size impossibly large.\n");
+         return RESULT_FAIL;
+       }
     }
 
   // reposition to start of RIP
index 43623f9ebdfc6a828ba40d59fd1f799fecf19742..829d114b051f0ce30af2ad4424c71fa39e1bca27 100644 (file)
@@ -40,16 +40,18 @@ endif
 
 # list of all the header files that should be installed
 include_HEADERS = KM_error.h KM_fileio.h KM_log.h KM_memio.h KM_mutex.h \
-               KM_platform.h KM_prng.h KM_util.h KM_tai.h KM_xml.h AS_DCP.h
+               KM_platform.h KM_prng.h KM_util.h KM_tai.h KM_xml.h AS_DCP.h AS_02.h
 if DEV_HEADERS
 include_HEADERS += S12MTimecode.h MDD.h Metadata.h KLV.h MXFTypes.h MXF.h Wav.h \
                PCMParserList.h
 nodist_include_HEADERS = TimedText_Transform.h
 endif
 
+
 # list of the libraries to build and install
-lib_LTLIBRARIES = libkumu.la libasdcp.la
-# sources for a library
+lib_LTLIBRARIES = libkumu.la libasdcp.la libas02.la
+
+# sources for kumu library
 libkumu_la_SOURCES = KM_error.h KM_fileio.cpp KM_fileio.h KM_log.cpp KM_log.h \
                KM_memio.h KM_mutex.h KM_platform.h KM_prng.cpp KM_prng.h KM_util.cpp \
                KM_util.h KM_xml.cpp KM_xml.h KM_tai.h KM_tai.cpp
@@ -57,10 +59,11 @@ libkumu_la_SOURCES = KM_error.h KM_fileio.cpp KM_fileio.h KM_log.cpp KM_log.h \
 # linker flags (*not* including libraries to link against) for a library
 libkumu_la_LDFLAGS = -release @VERSION@
 
-# sources for a library that don't get added to a distribution
+
+# sources for asdcp library that don't get added to a distribution
 nodist_libasdcp_la_SOURCES = Metadata_h.tt2 Metadata_cpp.tt2 \
                mxfgen.pl MXF_def.pl ullist.pl ULList.xml dict.xml DMS_Crypto.xml
-
+# sources for asdcp library
 libasdcp_la_SOURCES = MPEG2_Parser.cpp MPEG.cpp JP2K_Codestream_Parser.cpp \
                JP2K_Sequence_Parser.cpp JP2K.cpp PCM_Parser.cpp Wav.cpp \
                TimedText_Parser.cpp KLV.cpp Dict.cpp MXFTypes.cpp MXF.cpp \
@@ -69,23 +72,27 @@ libasdcp_la_SOURCES = MPEG2_Parser.cpp MPEG.cpp JP2K_Codestream_Parser.cpp \
                AS_DCP_PCM.cpp AS_DCP_TimedText.cpp PCMParserList.cpp \
                Wav.h WavFileWriter.h MXF.h Metadata.h \
                JP2K.h AS_DCP.h AS_DCP_internal.h KLV.h MPEG.h MXFTypes.h MDD.h \
-               PCMParserList.h S12MTimecode.h MDD.cpp \
-               AS_02_MXF.cpp AS_02_JP2K.cpp AS_02_PCM.cpp h__02_Reader.cpp h__02_Writer.cpp
-
+               PCMParserList.h S12MTimecode.h MDD.cpp
 if DEV_HEADERS
 nodist_libasdcp_la_SOURCES += TimedText_Transform.h TimedText_Transform.cpp
 endif
-
 libasdcp_la_LDFLAGS = -release @VERSION@
-
 # additional libraries to link against for a library
 libasdcp_la_LIBADD = libkumu.la
 libasdcp_la_CPPFLAGS = -DASDCP_PLATFORM=\"@host@\"
 
+
+# sources for as-02 library
+libas02_la_SOURCES     = \
+               AS_02.h AS_02_MXF.cpp AS_02_JP2K.cpp AS_02_PCM.cpp h__02_Reader.cpp h__02_Writer.cpp
+libas02_la_LDFLAGS = -release @VERSION@
+libas02_la_LIBADD = libasdcp.la libkumu.la
+libas02_la_CPPFLAGS = -DASDCP_PLATFORM=\"@host@\"
+
+
 # Python extension
 if PYTHON_USE
 lib_LTLIBRARIES += libpyasdcp.la
-#### libnapali.la
 
 nodist_libpyasdcp_la_SOURCES = \
        kumu_python.cpp \
@@ -100,22 +107,15 @@ nodist_libpyasdcp_la_SOURCES = \
        asdcp_python_mxf_text.cpp \
        asdcp_python_mxf_metadata.cpp
 
-####nodist_libnapali_la_SOURCES = \
-####   napali_python.cpp napali_python.h
 
 libpyasdcp_la_CPPFLAGS = @PYTHON_CPPFLAGS@
 libpyasdcp_la_LDFLAGS = @PYTHON_LSPEC@  -release @VERSION@
 libpyasdcp_la_LIBADD = libkumu.la libasdcp.la
 
-####libnapali_la_CPPFLAGS = @PYTHON_CPPFLAGS@
-####libnapali_la_LDFLAGS = @PYTHON_LSPEC@  -release @VERSION@
-####libnapali_la_LIBADD = libkumu.la libasdcp.la
-
 pyexecdir = @PYTHON_EXECDIR@
 pyexec_includedir = $(PYTHON_PREFIX)/include/python$(PYTHON_SHORTVERSION)
 nodist_pyexec_include_HEADERS = kumu_python.h asdcp_python.h asdcp_wrappers.h
 pyexec_LTLIBRARIES = kumu.la asdcp.la
-#### napali_python.h  napali.la
 
 nodist_kumu_la_SOURCES = pykumu.cpp kumu_python.h
 kumu_la_CPPFLAGS = @PYTHON_CPPFLAGS@
@@ -126,11 +126,6 @@ nodist_asdcp_la_SOURCES = pyasdcp.cpp kumu_python.h asdcp_python.h asdcp_wrapper
 asdcp_la_CPPFLAGS = @PYTHON_CPPFLAGS@
 asdcp_la_LDFLAGS = @PYTHON_LSPEC@ -avoid-version -module
 asdcp_la_LIBADD = libpyasdcp.la
-
-####nodist_napali_la_SOURCES = pynapali.cpp kumu_python.h napali_python.h
-####napali_la_CPPFLAGS = @PYTHON_CPPFLAGS@
-####napali_la_LDFLAGS = @PYTHON_LSPEC@ -avoid-version -module
-####napali_la_LIBADD = libnapali.la libpyasdcp.la
 endif
 
 # list of programs to be built and installed
@@ -145,10 +140,10 @@ asdcp_test_SOURCES = asdcp-test.cpp
 asdcp_test_LDADD = libasdcp.la
 
 as_02_wrap_SOURCES = as-02-wrap.cpp
-as_02_wrap_LDADD = libasdcp.la
+as_02_wrap_LDADD = libas02.la
 
 as_02_unwrap_SOURCES = as-02-unwrap.cpp
-as_02_unwrap_LDADD = libasdcp.la
+as_02_unwrap_LDADD = libas02.la
 
 asdcp_wrap_SOURCES = asdcp-wrap.cpp
 asdcp_wrap_LDADD = libasdcp.la
@@ -225,11 +220,9 @@ EXTRA_DIST = fips-186-test-harness.pl $(TESTS)
 if !FREEDIST
 if DEV_HEADERS
 EXTRA_DIST += $(nodist_libasdcp_la_SOURCES) $(nodist_tt_xform_SOURCES)
-#### $(nodist_napali_la_SOURCES) $(nodist_libnapali_la_SOURCES)
 endif
 if PYTHON_USE
 EXTRA_DIST += $(nodist_pyexec_include_HEADERS) $(nodist_libpyasdcp_la_SOURCES) $(nodist_kumu_la_SOURCES) $(nodist_asdcp_la_SOURCES)
-#### $(nodist_napali_la_SOURCES) $(nodist_libnapali_la_SOURCES)
 endif
 endif
 
index 0ff06606be840eb38f3339aa720893c115885e2e..919e89a687ef21f5925bca8e4163023bdfc38445 100644 (file)
@@ -447,17 +447,18 @@ Result_t AS_02::h__Writer::CreateBodyPartPair()
       m_BodyPartEssence->PreviousPartition = m_CurrentIndexBodyPartition->ThisPartition;\r
        m_HeaderPart.m_RIP.PairArray.push_back(RIP::Pair(m_CurrentIndexBodyPartition->BodySID, m_CurrentIndexBodyPartition->ThisPartition));
 
-       if(m_BodyPartList.size()>0){
-         m_CurrentIndexBodyPartition->PreviousPartition = m_BodyPartList.back()->ThisPartition;
-       }
-       else{
-         m_CurrentIndexBodyPartition->PreviousPartition = m_HeaderPart.ThisPartition;
-       }
+       if(m_BodyPartList.size()>0)
+         {
+           m_CurrentIndexBodyPartition->PreviousPartition = m_BodyPartList.back()->ThisPartition;
+         }
+       else
+         {
+           m_CurrentIndexBodyPartition->PreviousPartition = m_HeaderPart.ThisPartition;
+         }
 
        //necessary to traverse across all of the body partition packs and update the FooterPartition entries at the end of writing                     
        this->m_BodyPartList.push_back(m_CurrentIndexBodyPartition);
        this->m_BodyPartList.push_back(m_BodyPartEssence);
-
     }
 
   /* similar to both index strategies */