using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
//class Track;
//class Frame;
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#ifdef __cplusplus
extern "C" {
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
class KaxCluster;
class KaxReferenceBlock;
const KaxCluster * ParentCluster;
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_BLOCK_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
/*!
\brief element used for B frame-likes
void FreeBlob();
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_BLOCK_ADDITIONAL_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
class KaxSegment;
bool AddFrameInternal(const KaxTrackEntry & track, uint64 timecode, DataBuffer & buffer, KaxBlockGroup * & MyNewBlock, const KaxBlockGroup * PastBlock, const KaxBlockGroup * ForwBlock, LacingType lacing);
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_CLUSTER_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
extern const EbmlSemanticContext MATROSKA_DLL_API KaxMatroska_Context;
extern const EbmlSemanticContext MATROSKA_DLL_API KaxSegment_Context;
extern MATROSKA_DLL_API const EbmlSemanticContext & GetKaxGlobal_Context();
//extern MATROSKA_DLL_API const EbmlSemanticContext & GetKaxTagsGlobal_Context();
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_CONTEXTS_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
class KaxCuePoint;
uint64 mGlobalTimecodeScale;
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_CUES_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
class KaxBlockGroup;
class KaxBlockBlob;
void AddReference(const KaxBlockBlob & BlockReferenced, uint64 GlobalTimecodeScale);
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_CUES_DATA_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DECLARE_MKX_CONTEXT(KaxPrevUID)
class MATROSKA_DLL_API KaxPrevUID : public KaxSegmentUID {
EBML_CONCRETE_CLASS(KaxNextUID)
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_INFO_DATA_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
class KaxSegment;
KaxSeek * FindNextOf(const KaxSeek &aPrev) const;
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_SEEK_HEAD_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DECLARE_MKX_MASTER_CONS(KaxSegment)
public:
uint64 GetGlobalPosition(uint64 aRelativePosition) const;
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_SEGMENT_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DECLARE_MKX_BINARY (KaxSeekID)
public:
virtual bool ValidateSize() const {return IsFiniteSize() && GetSize() <= 4;}
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_SEMANTIC_H
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DECLARE_MKX_MASTER(KaxTrackEntry)
public:
uint64 mGlobalTimecodeScale;
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_TRACKS_H
#include "ebml/EbmlTypes.h"
#include "matroska/c/libmatroska_t.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
enum LacingType {
LACING_NONE = 0,
BLOCK_BLOB_ALWAYS_SIMPLE,
};
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_TYPES_H
#include "ebml/EbmlConfig.h"
#include "matroska/KaxConfig.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
#define LIBMATROSKA_VERSION 0x010604
\todo Improve the CRC/ECC system (backward and forward possible ?) to fit streaming/live writing/simple reading
*/
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#endif // LIBMATROSKA_VERSION_H
//#include "Frame.h"
//#include "Version.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
//typedef Track *TrackID;
}
#endif // OLD
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
void matroska_init()
{
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
KaxAttached::KaxAttached(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxAttached) EBML_DEF_SEP EBML_EXTRA_CALL)
SetSizeLength(2); // mandatory min size support (for easier updating) (2^(7*2)-2 = 16Ko)
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
using namespace LIBEBML_NAMESPACE;
// sub elements
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
KaxAttachments::KaxAttachments(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxAttachments) EBML_DEF_SEP EBML_EXTRA_CALL)
SetSizeLength(2); // mandatory min size support (for easier updating) (2^(7*2)-2 = 16Ko)
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxCluster.h"
#include "matroska/KaxDefines.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DataBuffer * DataBuffer::Clone()
{
return GetSize();
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
const KaxBlockBlob & KaxReferenceBlock::RefBlock() const
{
SetValueIsSet();
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxDefines.h"
// sub elements
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
KaxCluster::KaxCluster(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxCluster) EBML_DEF_SEP EBML_EXTRA_CALL)
return ParentSegment->GetRelativePosition(*this);
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
using namespace LIBEBML_NAMESPACE;
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DEFINE_START_SEMANTIC(KaxMatroska)
DEFINE_SEMANTIC_ITEM(true, true, EbmlHead)
return GetEbmlGlobal_Context();
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxSemantic.h"
// sub elements
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
KaxCues::~KaxCues()
{
return aTrack->ClusterPosition();
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxDefines.h"
#include "matroska/KaxSemantic.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
/*!
\todo handle codec state checking
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxDefines.h"
#include "matroska/KaxSemantic.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
#if defined(HAVE_EBML2) || defined(HAS_EBML2)
KaxSegmentUID::KaxSegmentUID(EBML_DEF_CONS EBML_DEF_SEP EBML_EXTRA_DEF)
}
#endif
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
using namespace LIBEBML_NAMESPACE;
// sub elements
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
/*!
\todo verify that the element is not already in the list
return (aEbmlIdA == aEbmlIdB);
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxContexts.h"
#include "matroska/KaxDefines.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
KaxSegment::KaxSegment(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxSegment) EBML_DEF_SEP EBML_EXTRA_CALL)
return aRelativePosition + GetElementPosition() + HeadSize();
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxBlockData.h"
#include "matroska/KaxCuesData.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
DEFINE_START_SEMANTIC(KaxSegment)
DEFINE_SEMANTIC_ITEM(false, false, KaxSeekHead)
return 0;
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxContexts.h"
#include "matroska/KaxDefines.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
KaxTrackEntry::KaxTrackEntry(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxTrackEntry) EBML_DEF_SEP EBML_EXTRA_CALL)
*(static_cast<EbmlUInteger *>(&myLacing)) = bEnable ? 1 : 0;
}
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "matroska/KaxVersion.h"
-START_LIBMATROSKA_NAMESPACE
+namespace libmatroska {
const std::string KaxCodeVersion = "1.6.4";
// remain binary compatible.
const std::string KaxCodeDate = "Unknown";
-END_LIBMATROSKA_NAMESPACE
+} // namespace libmatroska
#include "ebml/EbmlVersion.h"
#include "matroska/KaxVersion.h"
-using namespace LIBMATROSKA_NAMESPACE;
+using namespace libmatroska;
const char RW_FILENAME[] = "test.kax";
#include "matroska/KaxCues.h"
#include "matroska/KaxInfoData.h"
-using namespace LIBMATROSKA_NAMESPACE;
+using namespace libmatroska;
using namespace std;
unsigned int BIN_FILE_SIZE = 15000;
*(static_cast<EbmlFloat *>(&SegDuration)) = 0.0;
*((EbmlUnicodeString *)&GetChild<KaxMuxingApp>(MyInfos)) = L"libmatroska 0.5.0";
- *((EbmlUnicodeString *)&GetChild<KaxWritingApp>(MyInfos)) = L"éàôï";
+ *((EbmlUnicodeString *)&GetChild<KaxWritingApp>(MyInfos)) = L"����";
GetChild<KaxWritingApp>(MyInfos).SetDefaultSize(25);
filepos_t InfoSize = MyInfos.Render(out_file);
KaxChapterDisplay & aDisplay = GetChild<KaxChapterDisplay>(aAtom);
KaxChapterString & aChapString = GetChild<KaxChapterString>(aDisplay);
- *static_cast<EbmlUnicodeString *>(&aChapString) = L"Le film réduit à un chapitre";
+ *static_cast<EbmlUnicodeString *>(&aChapString) = L"Le film r�duit � un chapitre";
KaxChapterLanguage & aChapLang = GetChild<KaxChapterLanguage>(aDisplay);
*static_cast<EbmlString *>(&aChapLang) = "fra";
*static_cast<EbmlUnicodeString *>(&aTagName) = L"NAME";
KaxTagString & aTagtring = GetChild<KaxTagString>(TagSimple);
- *static_cast<EbmlUnicodeString *>(&aTagtring) = L"Testé123";
+ *static_cast<EbmlUnicodeString *>(&aTagtring) = L"Test�123";
filepos_t TagsSize = AllTags.Render(out_file, bWriteDefaultValues);
MetaSeek.IndexThis(AllTags, FileSegment);
#include "matroska/KaxCuesData.h"
#include "ebml/StdIOCallback.h"
-using namespace LIBMATROSKA_NAMESPACE;
+using namespace libmatroska;
using namespace std;
#define NO_DISPLAY_DATA
KaxWritingApp *pApp = static_cast<KaxWritingApp*>(ElementLevel2);
pApp->ReadData(aStream.I_O());
#if !defined(__CYGWIN__) && !defined(__APPLE__) && !defined(__BEOS__) && !defined(__NetBSD__)
- wprintf(L"Writing App : %ls (éàôï)\n", UTFstring(*pApp).c_str());
+ wprintf(L"Writing App : %ls (����)\n", UTFstring(*pApp).c_str());
#else
- printf("Writing App : %s (éàôï)\n", UTFstring(*pApp).c_str());
+ printf("Writing App : %s (����)\n", UTFstring(*pApp).c_str());
#endif
}
#include "FileName.hpp"
#include "StdIOCallback.hpp"
-using namespace LIBMATROSKA_NAMESPACE;
+using namespace libmatroska;
using namespace std;
/*!
int main(void)
{
string test1 = "lhomme";
- string test2 = "Stève"; // Supposed to be a UTF8 string
+ string test2 = "St�ve"; // Supposed to be a UTF8 string
// test2[2] = 0x0152; // oe mixed in one, upper case
// const wchar_t *toto = test2.c_str();
// in UTF8 0xE8=1110-1000 should become 110.00110-10.001000=0xC6 0x88
FileName test01(64);
- std::string str="..toto..txt éhé";
+ std::string str="..toto..txt �h�";
test01 = str;
FileName::name_level bType = test01.Test();
test01.MakeRelaxed();