#include <nnsys/snd.h>
#define NNS_SND_ARC_LOAD_BANK ( 1 << 1 )
#define NNS_SND_ARC_LOAD_WAVE ( 1 << 2 )
BOOL NNS_SndArcLoadBank( int bankNo, NNSSndHeapHandle heap );
BOOL NNS_SndArcLoadBankEx( int bankNo, u32 loadFlag, NNSSndHeapHandle heap );bankNo |
Bank number |
heap |
The sound heap handle |
loadFlag |
The flag that designates which data to load |
Loads the bank data to the heap.
The NNS_SndArcLoadBank function is loaded at the same time as the waveform archive associated with the bank data. The NNS_SndArcLoadBankEx function designates with loadFlag which of the two types of data to load. Put the following macros into loadFlag :
TABLE: Load Flags
| Macros | Constant | Description |
|---|---|---|
| NNS_SND_ARC_LOAD_BANK | 1 << 1 | The bank data |
| NNS_SND_ARC_LOAD_WAVE | 1 << 2 | The waveform archive |
The memory necessary for loading is automatically allocated from the sound heap heap with the NNS_SndHeapAlloc function. If memory allocation fails, the process is interrupted and a FALSE is returned.
Sound data that is already resident in memory is not loaded. Execution of the function NNS_SndArcGetFileAddress will determine whether or not the sound data is resident in memory. Also, the NNS_SndArcSetFileAddress function sets the address of the successfully loaded data.
Use this function only for the sound archive initialized with the NNS_SndArcInit function. This function cannot be used with the sound archive initialized with the NNS_SndArcInitOnMemory function.
NNS_SndHeapAlloc, NNS_SndArcGetFileAddress, NNS_SndArcSetFileAddress, NNS_SndArcInit, NNS_SndArcInitOnMemory
06/01/2004 Initial version.