#include <cafe/mp4dmx.h>

///MP4Movie Header Information Structure
typedef struct{
    ///moov header size
    s32     size;
    ///time scale
    s32     timescale;
    ///moov Play Time(Conversion time scale)
    u64     duration;
    ///Total playing time, including the fragment(Conversion time scale)
    u64     fragment_duration;
    ///A flag that indicates whether an mvex Box exists
    s32     mvexbox_exist_flag;
    ///Playback Rate
    s32     rate;
    ///Playback volume
    s32     volume;
    ///The number of tracks contained in the moov header
    s32     track_num;
    ///Major Brand
    u8      major_brand[5];
    ///Minor Version
    s32     minor_version;
    ///Number of Compatible Brands
    s32     compatible_brands_num;
    ///Compatible Brand
    u8      compatible_brands[MP4DMX_COMPATIBLE_DATA_LENGTH];
    ///Creation Time
    u64     creation_time;
    ///Modification Time
    u64     modification_time;
    ///The number of bytes Title information
    s32     title_length;
    ///The number of bytes Author information
    s32     author_length;
    ///The number of bytes Copyright information
    s32     copyright_length;
    ///The number of bytes Description
    s32     description_length;
    ///language code of title
    u16     title_language;
    ///language code of auther
    u16     author_language;
    ///language code of copyright
    u16     copyright_language;
    ///language code of description
    u16     description_language;
    u8      title[MP4DMX_UDTA_DATA_LENGTH];
    u8      author[MP4DMX_UDTA_DATA_LENGTH];
    u8      copyright[MP4DMX_UDTA_DATA_LENGTH];
    u8      description[MP4DMX_UDTA_DATA_LENGTH];
} MP4DMXMpoMp4HeaderInf;


size The size of the moov header.
timescale The time scale.
duration The moov playback time (in time scale units).
fragment_duration The total playback time, including fragments (in time scale units).
mvexBox_exist_flag A flag that indicates whether an mvex Box exists.
This is MP4DMX_MVEX_BOX_EXIST when there is an mvex Box.
rate The playback rate.
volume The playback volume.
track_num The number of tracks in the moov header.
major_brand The major brand.
minor_version The minor version.
compatible_brands_num The number of compatible brands.
compatible_brands The compatible brands. There are compatible_brands_num 4-byte strings stored as the compatible brands.
When compatible_brands_num is 4, for example, compatible_brands is avc1mmp43gp53gp4.
creation_time The file's creation time.
modification_time The file's last modification time.
title_length The number of bytes of title information.
author_length The number of bytes of author information.
copyright_length The number of bytes of copyright information.
description_length The number of bytes in the description.
title_language The title's language code.
author_language The author's language code.
copyright_language The copyright's language code.
description_language The description's language code.
title Title information.
author Author information.
copyright Copyright information.
description The description.

Original Data Referenced by the MP4DMXMpoMp4HeaderInf Structure

Member Variable Referencing Source
size moov->size
timescale mvhd->time_scale
duration mvhd->duration
fragment_duration mehd->fragment_duration
mvexbox_exist_flag mvex
rate mvhd->rate
volume mvhd->volume
track_num moov
major_brand ftyp->major_brand
minor_version ftyp-> minor_version
compatible_brands_num ftyp
compatible_brands ftyp-> compatible_brands
creation_time mvhd -> creation_time
modification_time mvhd -> modification_time
title_length titl
author_length auth
copyright_length cprt
description_length dscp
title_language titl->language
author_language auth-> language
copyright_language cprt-> language
description_language dscp-> language
title titl->title
author auth->author
copyright cprt->notice
description dscp->caption


This structure stores the header information that the library retrieves from MP4 data files. It can be retrieved using the utility functions for retrieving header information.

See Also


Revision History

2014-07-31 Initial topic creation.