#include <mo/Mobiclip.h>MOResult MOInit(MEMAllocator *pAllocator);| pAllocator | Memory allocator that will be used by libMobiclip. |
MO_RESULT_OK |
Initialization succeeded. |
MO_RESULT_ALREADY_INITIALIZED |
Already initialized. |
MO_RESULT_NULL |
Allocator is NULL. |
This function must be called before calling any other Mobiclip Library.
This call will initialize the library and provide it a heap to allocate memory from.
Please note the following:
The amount of memory needed by Mobiclip API depends on many factors:
Two macros are defined as helpers in the Mobiclip API to approximate the amount of memory needed for standard usages.
These are:
MO_MEMORY_NEEDED_VGA gives gross estimate of memory needed to perform single VGA video playback with a 48000Hz stereo audio track.MO_MEMORY_NEEDED_QVGA gives gross estimate of memory needed to perform single QVGA video playback with a 48000Hz stereo audio track.In many cases the amount of memory needed will be significantly less than specified in these macros.
If you want to fine tune the size of the heap you'll give to the MOInit function, the MOMemStat function can give useful informations on the memory usage inside Mobiclip API.
03/26/2009 Parameter renaming done. Added note on memory usage. Added link to MOMemStat function.
07/29/2008 Initial version.