MFHD box
This commit is contained in:
parent
bf8bc34dd0
commit
3fde290ed6
2 changed files with 41 additions and 0 deletions
27
MP4/box_mfhd.cpp
Normal file
27
MP4/box_mfhd.cpp
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
#include "box_mfhd.h"
|
||||||
|
|
||||||
|
Box_mfhd::Box_mfhd( ) {
|
||||||
|
Container = new Box( 0x6D666864 );
|
||||||
|
SetDefaults( );
|
||||||
|
SetReserved( )
|
||||||
|
}
|
||||||
|
|
||||||
|
Box_mfhd::~Box_mfhd() {
|
||||||
|
delete Container;
|
||||||
|
}
|
||||||
|
|
||||||
|
Box * Box_mfhd::GetBox() {
|
||||||
|
return Container;
|
||||||
|
}
|
||||||
|
|
||||||
|
void Box_mfhd::SetDefaults( ) {
|
||||||
|
SetSequenceNumber( );
|
||||||
|
}
|
||||||
|
|
||||||
|
void Box_mfhd::SetDefaults( ) {
|
||||||
|
Container->SetPayload((uint32_t)4,Box::uint32_to_uint8(0));
|
||||||
|
}
|
||||||
|
|
||||||
|
void SetSequenceNumber( uint32_t SequenceNumber );
|
||||||
|
Container->SetPayload((uint32_t)4,Box::uint32_to_uint8(SequenceNumber),4);
|
||||||
|
}
|
14
MP4/box_mfhd.h
Normal file
14
MP4/box_mfhd.h
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
#include "box.h"
|
||||||
|
|
||||||
|
class Box_mfhd {
|
||||||
|
public:
|
||||||
|
Box_mfhd( );
|
||||||
|
~Box_mfhd();
|
||||||
|
Box * GetBox();
|
||||||
|
void SetSequenceNumber( uint32_t SequenceNumber = 1 );
|
||||||
|
private:
|
||||||
|
void SetDefaults( );
|
||||||
|
void SetReserved( );
|
||||||
|
Box * Container;
|
||||||
|
};//Box_ftyp Class
|
||||||
|
|
Loading…
Add table
Reference in a new issue