Skip to content

Commit

Permalink
MXFDump: add dump of generic stream partition packs
Browse files Browse the repository at this point in the history
  • Loading branch information
philipnbbc committed Mar 28, 2024
1 parent b56943d commit a6913c2
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
15 changes: 15 additions & 0 deletions deps/libMXF/tools/MXFDump/MXFDump.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5294,6 +5294,8 @@ void destroyPartitions(PartitionList& partitions)
// OpenBody 06 0e 2b 34 02 05 01 01 0d 01 02 01 01 03 03 00
// Body 06 0e 2b 34 02 05 01 01 0d 01 02 01 01 03 04 00
//
// GenericStream 06 0e 2b 34 02 05 01 01 0d 01 02 01 01 03 11 00
//
// IncompleteFooter 06 0e 2b 34 02 05 01 01 0d 01 02 01 01 04 02 00
// Footer 06 0e 2b 34 02 05 01 01 0d 01 02 01 01 04 04 00
//
Expand Down Expand Up @@ -5326,6 +5328,8 @@ bool isPartition(mxfKey& key)
result = true;
} else if (memcmp(&Body, &key, sizeof(mxfKey)) == 0) {
result = true;
} else if (memcmp(&GenericStream, &key, sizeof(mxfKey)) == 0) {
result = true;
} else if (memcmp(&IncompleteFooter, &key, sizeof(mxfKey)) == 0) {
result = true;
} else if (memcmp(&Footer, &key, sizeof(mxfKey)) == 0) {
Expand Down Expand Up @@ -5377,6 +5381,8 @@ bool isClosed(const mxfKey& key)
result = true;
} else if (memcmp(&Body, &key, sizeof(mxfKey)) == 0) {
result = true;
} else if (memcmp(&GenericStream, &key, sizeof(mxfKey)) == 0) {
result = true;
} else if (memcmp(&IncompleteFooter, &key, sizeof(mxfKey)) == 0) {
result = true;
} else if (memcmp(&Footer, &key, sizeof(mxfKey)) == 0) {
Expand Down Expand Up @@ -5728,6 +5734,13 @@ void printBodyPartition(mxfKey& k, mxfLength& len, mxfFile infile)
printPartition(k, len, infile);
}

void printGenericStreamPartition(mxfKey& k, mxfLength& len, mxfFile infile);

void printGenericStreamPartition(mxfKey& k, mxfLength& len, mxfFile infile)
{
printPartition(k, len, infile);
}

void printFooterPartition(mxfKey& k, mxfLength& len, mxfFile infile);

void printFooterPartition(mxfKey& k, mxfLength& len, mxfFile infile)
Expand Down Expand Up @@ -6640,6 +6653,8 @@ void mxfDumpKLV(mxfKey& k, mxfLength& len, mxfFile infile)
printBodyPartition(k, len, infile);
} else if (memcmp(&Body, &k, sizeof(mxfKey)) == 0) {
printBodyPartition(k, len, infile);
} else if (memcmp(&GenericStream, &k, sizeof(mxfKey)) == 0) {
printGenericStreamPartition(k, len, infile);
} else if (memcmp(&IncompleteFooter, &k, sizeof(mxfKey)) == 0) {
printFooterPartition(k, len, infile);
} else if (memcmp(&Footer, &k, sizeof(mxfKey)) == 0) {
Expand Down
7 changes: 7 additions & 0 deletions deps/libMXF/tools/MXFDump/MXFMetaDictionary.h
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,13 @@ MXF_DEFINE_PACK_KEY(Body,
MXF_LABEL(0x06, 0x0e, 0x2b, 0x34, 0x02, 0x05, 0x01, 0x01,
0x0d, 0x01, 0x02, 0x01, 0x01, 0x03, 0x04, 0x00))

// Generic Stream Partition Pack
//
// 06.0e.2b.34.02.05.01.01.0d.01.02.01.01.03.11.00
MXF_DEFINE_PACK_KEY(GenericStream,
MXF_LABEL(0x06, 0x0e, 0x2b, 0x34, 0x02, 0x05, 0x01, 0x01,
0x0d, 0x01, 0x02, 0x01, 0x01, 0x03, 0x11, 0x00))

// Footer Partition Pack
//
// 06.0e.2b.34.02.05.01.01.0d.01.02.01.01.04.02.00
Expand Down

0 comments on commit a6913c2

Please sign in to comment.