s32 nuAuMgrInit(void *heap_ptr, u32 size, ALSynConfig *synConfig)
s32 nuAuMgrInitEx(void *heap_ptr, u32 size, ALSynConfig *synConfig)
heap_ptr pointer to buffer used as audio heap
size heap size
synConfig pointer to synthesizer driver setting structure
Heap size consumed
Initializes the audio manager, creates and starts the audio manager thread. Also initializes and starts the synthesizer drivers.
The return value is the size of the heap being used.
The audio manager which is created and started by the nuAuMgrInit function plays back audio using retrace events. This is the method that has been used up until now.
The audio manager created and started by the nuAuMgrInitEx function plays back audio using retrace events and AI events. This is a new audio manager. Since AI-DMA control can be reliably and efficiently accomplished when this audio manager is used, the AI buffer is empty and noise is unlikely to occur. In addition, two audio data buffers are sufficient.
The difference between these two audio managers is the timing with which audio tasks are executed. In the case of the conventional audio manager, audio tasks are executed immediately after a retrace event. However, when AI events are used, audio tasks are executed when the AI-DMA register becomes empty. In addition, due to restrictions on the smallest processing unit in the audio microcode, audio data cannot be created accurately in one-frame pieces. Consequently, since the audio task execution timing changes for each frame, care is required as this may affect graphics tasks.
alHeapInit and alInit
2/1/99 Added description regarding nuAuMgrInitEx function.