More boxes
This commit is contained in:
parent
6d1ae13193
commit
927996365e
9 changed files with 206 additions and 1 deletions
25
MP4/box_mdhd.cpp
Normal file
25
MP4/box_mdhd.cpp
Normal file
|
@ -0,0 +1,25 @@
|
|||
#include "box_mdhd.h"
|
||||
|
||||
Box_mdhd::Box_mdhd( ) {
|
||||
Container = new Box( 0x6D646864 );
|
||||
}
|
||||
|
||||
Box_mdhd::~Box_mdhd() {
|
||||
delete Container;
|
||||
}
|
||||
|
||||
Box * Box_mdhd::GetBox() {
|
||||
return Container;
|
||||
}
|
||||
|
||||
void Box_mdhd::SetLanguage( uint8_t Firstchar, uint8_t Secondchar, uint8_t Thirdchar ) {
|
||||
uint8_t FirstByte = 0;
|
||||
uint8_t SecondByte = 0;
|
||||
Firstchar -= 0x60;
|
||||
Secondchar -= 0x60;
|
||||
Thirdchar -= 0x60;
|
||||
FirstByte += (Firstchar << 2);
|
||||
FirstByte += (Secondchar >> 3);
|
||||
SecondByte += (Secondchar << 5);
|
||||
SecondByte += Thirdchar;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue