MP4DMX Data Definitions

This section describes the data used when setting parameters.

Table of Contents

Input Parameter Settings

The following table lists the MP4DMX input parameters along with descriptions.

Type Parameter Name Description Required?
u8* MP4DMX_OUT_VIDEO_FLAG A flag that indicates whether video will be output. Maybe
u8* MP4DMX_OUT_AUDIO_FLAG A flag that indicates whether audio will be output. Maybe
s32 MP4DMX_OUT_ONLY_KEYFRAME Configures video output to only include key frames. Maybe
s32 MP4DMX_STTS_READ_BUFFER_SIZE Sets the buffer size to use to read an stts Box in parts. Maybe
s32 MP4DMX_STSZ_READ_BUFFER_SIZE Sets the buffer size to use to read an stsz Box in parts. Maybe
s32 MP4DMX_CTTS_READ_BUFFER_SIZE Sets the buffer size to use to read a ctts Box in parts. Maybe
void* MP4DMX_MPO_OUTPUT_FUNCTION A handle and pointer to the output callback function. Always
s32 MP4DMX_MPO_PARAMETER_END Indicates the end of an argument array. Always

NOTE:
Maybe indicates that under certain conditions it may be required.

Input Parameters Details

Details regarding the input parameters are given in the following tables.

Input parameters are set by storing them in the MP4DMXMpoPARAMETER structure and passing it to the initialization function MP4DMXOpen.

MP4DMX_OUT_VIDEO_FLAG

Description A pointer to a flag that indicates whether video will be output.
Type u8*
Values NULL or a pointer to a flag (where 0 means that video will not be output and 1 means that video will be output).
Default Value NULL (1: output video).
Comments This is an optional parameter.

MP4DMX_OUT_AUDIO_FLAG

Description A pointer to a flag that indicates whether audio will be output.
Type u8*
Values NULL or a pointer to a flag (where 0 means that audio will not be output and 1 means that audio will be output).
Default Value NULL (1: output audio).
Comments This is an optional parameter.

MP4DMX_OUT_ONLY_KEYFRAME

Description A flag that configures video output only for key frames.
Type s32
Values 0: Output all frames.
1: Output key frames only.
Default Value 0: Output all frames.
Comments This is an optional parameter.

MP4DMX_STTS_READ_BUFFER_SIZE

Description Configures the number of bytes in which to split up an stts Box when it is read.
Type s32
Values 32 KB
Default Value Do not split up (read it all into memory).
Comments This is an optional parameter.
Any stts Box that is split up when it is read is assumed to be split into blocks of a fixed size (32 KB). Library behavior is guaranteed as long as this size is used.

MP4DMX_STSZ_READ_BUFFER_SIZE

Description Configures the number of bytes in which to split up an stsz Box when it is read.
Type s32
Values 32 KB
Default Value Do not split up (read it all into memory).
Comments This is an optional parameter.
Any stsz Box that is split up when it is read is assumed to be split into blocks of a fixed size (32 KB). Library behavior is guaranteed as long as this size is used.

MP4DMX_CTTS_READ_BUFFER_SIZE

Description Configures the number of bytes in which to split up a ctts Box when it is read.
Type s32
Values 32 KB
Default Value Do not split up (read it all into memory).
Comments This is an optional parameter.
Any ctts Box that is split up when it is read is assumed to be split into blocks of a fixed size (32 KB). Library behavior is guaranteed as long as this size is used.

MP4DMX_MPO_OUTPUT_FUNCTION

Description A pointer to an MP4DMXMpoOutputFunction structure.
Type void *
Values -
Default Value -
Comments This is a required parameter.

MP4DMX_MPO_PARAMETER_END

Description Indicates the end of the parameter array.
Type -
Values -
Default Value -
Comments This is a required parameter.

Error Codes

Negative values returned by any of the API functions indicate an error. The error codes are given in the following table.

Identifier Value Description
MP4DMX_RET_ERROR_NOT_ENOUGH_MEMORY -9999999 The necessary memory could not be allocated.
MP4DMX_RET_ERROR_BADPARAM -9999998 An input parameter was invalid.
MP4DMX_RET_ERROR_INVALID_POINTER -9999996 An input argument was NULL.
MP4DMX_RET_ERROR_FATAL -9999995 The functions were not called in the correct order.
MP4DMX_RET_ERROR_BAD_STREAM -9999992 An error was detected in the input MP4 data in memory.
MP4DMX_RET_ERROR_BAD_TIMESTAMP -9999991 An input timestamp exceeds the duration of the current stream.
MP4DMX_RET_INVALID_TRACK_ID -9999990 The specified track ID is not supported.
MP4DMX_RET_INVALID_TRACK_INDEX -9999989 A track for the specified index does not exist.
MP4DMX_RET_NOT_FOUND -9999988 The specified item does not exist.
MP4DMX_RET_ERROR -1 The callback function exited abnormally.

Revision History

2014-08-04 Initial version.


CONFIDENTIAL