Change History
+new stuff:
+ o UL version byte now ignored when comparing UL values.
+ o JP2K Sequence Parser modified to skip directory entries that
+ are not files in the case where the parser is initialized with
+ a directory path. When initialized with a list of file names
+ this check is not performed. Based on a hint by Steve Q.
+ o Added missing FrameType() implementation to ASDCP::MPEG2::MXFReader.
+ o Added missing Close() implementations to MXF reader classes.
+ o Added missing Timestamp::Timestamp(const char* datestr)
+ implementation. (Thanks to Matt Sheby for this and the previous
+ item)
+
+
+
+
+
+
2010.11.15 - bug fixes, enhancements v1.7.40
- o Fixed bug in long KLV packet support (Thanks to Jim R.).
+ o Fixed bug in long KLV packet support (Thanks to Jim Radford).
o Fixed AvgBps in PCM files, *again*. Sorry for the crazy.
o More fixes and changes in support of 25, 30, 50, 60 fps.
(Thanks to Hans K. for the TC rate bug).
o Updated KLVFill UL version element to 0x02.
- o Type change to support Xerces-C 3.x. (Thanks to Matt S.).
+ o Type change to support Xerces-C 3.x. (Thanks to Matt Sheby).
o Some internal API changes to KLV types. Does not affect
operation.
o Added NetworkLocator type to MXF metadata types.
m_Reader->m_FooterPart.Dump(stream);
}
+//
+ASDCP::Result_t
+ASDCP::JP2K::MXFReader::Close() const
+{
+ if ( m_Reader && m_Reader->m_File.IsOpen() )
+ {
+ m_Reader->Close();
+ return RESULT_OK;
+ }
+
+ return RESULT_INIT;
+}
+
//------------------------------------------------------------------------------------------
m_Reader->m_FooterPart.Dump(stream);
}
+//
+ASDCP::Result_t
+ASDCP::JP2K::MXFSReader::Close() const
+{
+ if ( m_Reader && m_Reader->m_File.IsOpen() )
+ {
+ m_Reader->Close();
+ return RESULT_OK;
+ }
+
+ return RESULT_INIT;
+}
+
+
//------------------------------------------------------------------------------------------
/*
-Copyright (c) 2004-2010, John Hurst
+Copyright (c) 2004-2011, John Hurst
All rights reserved.
Redistribution and use in source and binary forms, with or without
Result_t ReadFrame(ui32_t, FrameBuffer&, AESDecContext*, HMACContext*);
Result_t ReadFrameGOPStart(ui32_t, FrameBuffer&, AESDecContext*, HMACContext*);
Result_t FindFrameGOPStart(ui32_t, ui32_t&);
+ Result_t FrameType(ui32_t FrameNum, FrameType_t& type);
};
return RESULT_OK;
}
+//
+ASDCP::Result_t
+ASDCP::MPEG2::MXFReader::h__Reader::FrameType(ui32_t FrameNum, FrameType_t& type)
+{
+ if ( ! m_File.IsOpen() )
+ return RESULT_INIT;
+
+ // look up frame index node
+ IndexTableSegment::IndexEntry TmpEntry;
+
+ if ( ASDCP_FAILURE(m_FooterPart.Lookup(FrameNum, TmpEntry)) )
+ {
+ DefaultLogSink().Error("Frame value out of range: %u\n", FrameNum);
+ return RESULT_RANGE;
+ }
+
+ type = ( (TmpEntry.Flags & 0x0f) == 3 ) ? FRAME_B : ( (TmpEntry.Flags & 0x0f) == 2 ) ? FRAME_P : FRAME_I;
+ return RESULT_OK;
+}
+
//
//
m_Reader->m_FooterPart.Dump(stream);
}
+//
+ASDCP::Result_t
+ASDCP::MPEG2::MXFReader::Close() const
+{
+ if ( m_Reader && m_Reader->m_File.IsOpen() )
+ {
+ m_Reader->Close();
+ return RESULT_OK;
+ }
+
+ return RESULT_INIT;
+}
+
+//
+ASDCP::Result_t
+ASDCP::MPEG2::MXFReader::FrameType(ui32_t FrameNum, FrameType_t& type) const
+{
+ if ( ! m_Reader )
+ return RESULT_INIT;
+
+ return m_Reader->FrameType(FrameNum, type);
+}
+
//------------------------------------------------------------------------------------------
m_Reader->m_FooterPart.Dump(stream);
}
+//
+ASDCP::Result_t
+ASDCP::PCM::MXFReader::Close() const
+{
+ if ( m_Reader && m_Reader->m_File.IsOpen() )
+ {
+ m_Reader->Close();
+ return RESULT_OK;
+ }
+
+ return RESULT_INIT;
+}
+
//------------------------------------------------------------------------------------------
/*
-Copyright (c) 2008-2009, John Hurst
+Copyright (c) 2008-2011, John Hurst
All rights reserved.
Redistribution and use in source and binary forms, with or without
m_Reader->m_FooterPart.Dump(stream);
}
+//
+ASDCP::Result_t
+ASDCP::TimedText::MXFReader::Close() const
+{
+ if ( m_Reader && m_Reader->m_File.IsOpen() )
+ {
+ m_Reader->Close();
+ return RESULT_OK;
+ }
+
+ return RESULT_INIT;
+}
+
+
//------------------------------------------------------------------------------------------
/*
-Copyright (c) 2004-2009, John Hurst
+Copyright (c) 2004-2011, John Hurst
All rights reserved.
Redistribution and use in source and binary forms, with or without
std::string Str(m_DirName);
Str += "/";
Str += next_file;
- push_back(Str);
+
+ if ( ! Kumu::PathIsDirectory(Str) )
+ push_back(Str);
}
sort();
virtual ~UL() {}
const char* EncodeString(char* str_buf, ui32_t buf_len) const;
+ bool operator==(const UL& rhs) const;
};
// UMID
Second = rhs.Second;
}
+//
+Kumu::Timestamp::Timestamp(const char* datestr) : IArchive()
+{
+ if ( ! DecodeString(datestr) )
+ {
+ *this = Timestamp();
+ }
+}
+
+//
Kumu::Timestamp::~Timestamp()
{
}
{ { 0x06, 0x0e, 0x2b, 0x34, 0x04, 0x01, 0x01, 0x0a, // 255
0x0d, 0x01, 0x03, 0x01, 0x02, 0x13, 0x01, 0x01 },
{0}, false, "TimedTextWrapping" },
- { { 0x06, 0x0e, 0x2b, 0x34, 0x01, 0x02, 0x01, 0x09, // 256
+ { { 0x06, 0x0e, 0x2b, 0x34, 0x01, 0x02, 0x01, 0x01, // 256
0x0d, 0x01, 0x03, 0x01, 0x17, 0x01, 0x0b, 0x01 },
{0}, false, "TimedTextEssence" },
{ { 0x06, 0x0e, 0x2b, 0x34, 0x02, 0x53, 0x01, 0x01, // 257
//------------------------------------------------------------------------------------------
//
+bool
+ASDCP::UL::operator==(const UL& rhs) const
+{
+ if ( m_Value[0] == rhs.m_Value[0] &&
+ m_Value[1] == rhs.m_Value[1] &&
+ m_Value[2] == rhs.m_Value[2] &&
+ m_Value[3] == rhs.m_Value[3] &&
+ m_Value[4] == rhs.m_Value[4] &&
+ m_Value[5] == rhs.m_Value[5] &&
+ m_Value[6] == rhs.m_Value[6] &&
+ // m_Value[7] == rhs.m_Value[7] && version is ignored when performing lookups
+ m_Value[8] == rhs.m_Value[8] &&
+ m_Value[9] == rhs.m_Value[9] &&
+ m_Value[10] == rhs.m_Value[10] &&
+ m_Value[11] == rhs.m_Value[11] &&
+ m_Value[12] == rhs.m_Value[12] &&
+ m_Value[13] == rhs.m_Value[13] &&
+ m_Value[14] == rhs.m_Value[14] &&
+ m_Value[15] == rhs.m_Value[15]
+ )
+ return true;
+
+ return false;
+}
+
+
const char*
ASDCP::UL::EncodeString(char* str_buf, ui32_t buf_len) const
{
# 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_xml.h AS_DCP.h
+ KM_platform.h KM_prng.h KM_util.h KM_tai.h KM_xml.h AS_DCP.h
if DEV_HEADERS
include_HEADERS += S12MTimecode.h MDD.h Metadata.h KLV.h MXFTypes.h MXF.h Wav.h \
PCMParserList.h
/*
-Copyright (c) 2004-2009, John Hurst
+Copyright (c) 2004-2011, John Hurst
All rights reserved.
Redistribution and use in source and binary forms, with or without