Skip to content

Commit

Permalink
remove use of legacy libebml macros
Browse files Browse the repository at this point in the history
They are now removed and were doing nothing.
  • Loading branch information
robUx4 committed Dec 18, 2023
1 parent 75759e3 commit 431b942
Show file tree
Hide file tree
Showing 12 changed files with 34 additions and 34 deletions.
6 changes: 3 additions & 3 deletions matroska/KaxBlock.h
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ DECLARE_MKX_MASTER(KaxBlockGroup)

class MATROSKA_DLL_API KaxInternalBlock : public EbmlBinary {
public:
KaxInternalBlock(EBML_DEF_CONS EBML_DEF_SEP bool bSimple EBML_DEF_SEP EBML_EXTRA_PARAM) :EBML_DEF_BINARY_INIT EBML_DEF_SEP bIsSimple(bSimple)
KaxInternalBlock(bool bSimple) :bIsSimple(bSimple)
{}
KaxInternalBlock(const KaxInternalBlock & ElementToClone);
~KaxInternalBlock() override;
Expand Down Expand Up @@ -292,14 +292,14 @@ class MATROSKA_DLL_API KaxInternalBlock : public EbmlBinary {
DECLARE_MKX_CONTEXT(KaxBlock)
class MATROSKA_DLL_API KaxBlock : public KaxInternalBlock {
public:
KaxBlock(EBML_EXTRA_PARAM) :KaxInternalBlock(EBML_DEF_BINARY_CTX(KaxBlock)EBML_DEF_SEP false EBML_DEF_SEP EBML_EXTRA_CALL) {}
KaxBlock() :KaxInternalBlock(false) {}
EBML_CONCRETE_CLASS(KaxBlock)
};

DECLARE_MKX_CONTEXT(KaxSimpleBlock)
class MATROSKA_DLL_API KaxSimpleBlock : public KaxInternalBlock {
public:
KaxSimpleBlock(EBML_EXTRA_PARAM) :KaxInternalBlock(EBML_DEF_BINARY_CTX(KaxSimpleBlock)EBML_DEF_SEP true EBML_DEF_SEP EBML_EXTRA_CALL) {}
KaxSimpleBlock() :KaxInternalBlock(true) {}

void SetKeyframe(bool b_keyframe) { bIsKeyframe = b_keyframe; }
void SetDiscardable(bool b_discard) { bIsDiscardable = b_discard; }
Expand Down
22 changes: 11 additions & 11 deletions matroska/KaxDefines.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,67 +59,67 @@

#define DECLARE_MKX_MASTER(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlMaster { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlMaster(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_MASTER_CONS(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlMaster { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone); \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_BINARY(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlBinary { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlBinary(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_BINARY_CONS(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlBinary { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone); \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_UNISTRING(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlUnicodeString { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlUnicodeString(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_STRING(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlString { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlString(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_UINTEGER(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlUInteger { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlUInteger(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_SINTEGER_CONS(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlSInteger { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone); \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_SINTEGER(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlSInteger { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlSInteger(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_DATE(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlDate { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlDate(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

#define DECLARE_MKX_FLOAT(x) DECLARE_MKX_CONTEXT(x) \
class MATROSKA_DLL_API x : public EbmlFloat { \
public: x(EBML_EXTRA_PARAM); \
public: x(); \
x(const x & ElementToClone) :EbmlFloat(ElementToClone) {} \
EBML_CONCRETE_CLASS(x)

Expand Down
4 changes: 2 additions & 2 deletions matroska/KaxInfoData.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ namespace libmatroska {
DECLARE_MKX_CONTEXT(KaxPrevUID)
class MATROSKA_DLL_API KaxPrevUID : public KaxSegmentUID {
public:
KaxPrevUID(EBML_EXTRA_PARAM) = default;
KaxPrevUID() = default;
KaxPrevUID(const KaxPrevUID & ElementToClone) = default;
bool ValidateSize() const override { return IsFiniteSize() && (GetSize() == 16);}

Expand All @@ -63,7 +63,7 @@ class MATROSKA_DLL_API KaxPrevUID : public KaxSegmentUID {
DECLARE_MKX_CONTEXT(KaxNextUID)
class MATROSKA_DLL_API KaxNextUID : public KaxSegmentUID {
public:
KaxNextUID(EBML_EXTRA_PARAM) = default;
KaxNextUID() = default;
KaxNextUID(const KaxNextUID & ElementToClone) = default;
bool ValidateSize() const override { return IsFiniteSize() && (GetSize() == 16);}

Expand Down
4 changes: 2 additions & 2 deletions matroska/KaxSemantic.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ DECLARE_MKX_MASTER(KaxInfo)
DECLARE_MKX_BINARY (KaxSegmentUID)
#if defined(HAVE_EBML2) || defined(HAS_EBML2)
public:
KaxSegmentUID(EBML_DEF_CONS EBML_DEF_SEP EBML_EXTRA_PARAM);
KaxSegmentUID();
#endif
public:
bool ValidateSize() const override {return IsFiniteSize() && GetSize() == 16;}
Expand Down Expand Up @@ -1197,7 +1197,7 @@ typedef enum {
*Indicate what type of content the ChapterAtom contains and might be skipped. It can be used to automatically skip content based on the type.
If a `ChapterAtom` is inside a `ChapterAtom` that has a `ChapterSkipType` set, it **MUST NOT** have a `ChapterSkipType` or have a `ChapterSkipType` with the same value as it's parent `ChapterAtom`.
If the `ChapterAtom` doesn't contain a `ChapterTimeEnd`, the value of the `ChapterSkipType` is only valid until the next `ChapterAtom` with a `ChapterSkipType` value or the end of the file.
*/
typedef enum {
MATROSKA_CHAPTERSKIPTYPE_NO_SKIPPING = 0, // Content which should not be skipped.
Expand Down
4 changes: 2 additions & 2 deletions src/KaxAttached.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ using namespace libebml;

namespace libmatroska {

KaxAttached::KaxAttached(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxAttached) EBML_DEF_SEP EBML_EXTRA_CALL)
KaxAttached::KaxAttached()
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxAttached))
{
SetSizeLength(2); // mandatory min size support (for easier updating) (2^(7*2)-2 = 16Ko)
}
Expand Down
4 changes: 2 additions & 2 deletions src/KaxAttachments.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ using namespace libebml;
// sub elements
namespace libmatroska {

KaxAttachments::KaxAttachments(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxAttachments) EBML_DEF_SEP EBML_EXTRA_CALL)
KaxAttachments::KaxAttachments()
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxAttachments))
{
SetSizeLength(2); // mandatory min size support (for easier updating) (2^(7*2)-2 = 16Ko)
}
Expand Down
6 changes: 3 additions & 3 deletions src/KaxBlock.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,8 @@ KaxInternalBlock::KaxInternalBlock(const KaxInternalBlock & ElementToClone)
//NOTE("KaxBlockGroup::~KaxBlockGroup");
} */

KaxBlockGroup::KaxBlockGroup(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxBlockGroup) EBML_DEF_SEP EBML_EXTRA_CALL)
KaxBlockGroup::KaxBlockGroup()
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxBlockGroup))
{}

static constexpr std::int64_t SignedVINT_Shift1 = (1 << ((7*1) - 1)) - 1;
Expand Down Expand Up @@ -291,7 +291,7 @@ KaxBlockVirtual::KaxBlockVirtual(const KaxBlockVirtual & ElementToClone)
SetValueIsSet(false);
}

KaxBlockVirtual::KaxBlockVirtual(EBML_EXTRA_DEF)
KaxBlockVirtual::KaxBlockVirtual()
{
SetBuffer(DataBlock,sizeof(DataBlock));
SetValueIsSet(false);
Expand Down
2 changes: 1 addition & 1 deletion src/KaxBlockData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ const KaxBlockBlob & KaxReferenceBlock::RefBlock() const
return *RefdBlock;
}

KaxReferenceBlock::KaxReferenceBlock(EBML_EXTRA_DEF)
KaxReferenceBlock::KaxReferenceBlock()
{
bTimecodeSet = false;
}
Expand Down
4 changes: 2 additions & 2 deletions src/KaxCluster.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
// sub elements
namespace libmatroska {

KaxCluster::KaxCluster(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxCluster) EBML_DEF_SEP EBML_EXTRA_CALL)
KaxCluster::KaxCluster()
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxCluster))
{}

KaxCluster::KaxCluster(const KaxCluster & ElementToClone)
Expand Down
4 changes: 2 additions & 2 deletions src/KaxInfoData.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
namespace libmatroska {

#if defined(HAVE_EBML2) || defined(HAS_EBML2)
KaxSegmentUID::KaxSegmentUID(EBML_DEF_CONS EBML_DEF_SEP EBML_EXTRA_DEF)
:EbmlBinary(EBML_DEF_PARAM EBML_DEF_SEP EBML_EXTRA_CALL)
KaxSegmentUID::KaxSegmentUID()
:EbmlBinary(EBML_DEF_PARAM)
{
}
#endif
Expand Down
4 changes: 2 additions & 2 deletions src/KaxSegment.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@

namespace libmatroska {

KaxSegment::KaxSegment(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxSegment) EBML_DEF_SEP EBML_EXTRA_CALL)
KaxSegment::KaxSegment()
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxSegment))
{
SetSizeLength(5); // mandatory min size support (for easier updating) (2^(7*5)-2 = 32Go)
SetSizeInfinite(); // by default a segment is big and the size is unknown in advance
Expand Down
4 changes: 2 additions & 2 deletions src/KaxTracks.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@

namespace libmatroska {

KaxTrackEntry::KaxTrackEntry(EBML_EXTRA_DEF)
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxTrackEntry) EBML_DEF_SEP EBML_EXTRA_CALL)
KaxTrackEntry::KaxTrackEntry()
:EbmlMaster(EBML_CLASS_SEMCONTEXT(KaxTrackEntry))
{}

void KaxTrackEntry::EnableLacing(bool bEnable)
Expand Down

0 comments on commit 431b942

Please sign in to comment.