import: header file the jlsound functions, with the function prototypes
This commit is contained in:
parent
f68595821f
commit
0c3ed17dd4
1 changed files with 56 additions and 0 deletions
56
joeylib/src/iigs/sound.h
Normal file
56
joeylib/src/iigs/sound.h
Normal file
|
@ -0,0 +1,56 @@
|
|||
/*
|
||||
JoeyLib Sound Header File, with Sound Function Prototypes
|
||||
*/
|
||||
#ifndef JL_SOUND_H
|
||||
#define JL_SOUND_H
|
||||
|
||||
typedef struct
|
||||
{
|
||||
|
||||
} jlSound_t;
|
||||
|
||||
/* jlSoundT - A pointer to a sound bank / collection of sounds */
|
||||
typedef jlSound_t* jlSoundT;
|
||||
|
||||
/* Call this before any other Sound Function */
|
||||
void jlSoundStartup();
|
||||
/* Call this when done, for proper shutdown */
|
||||
void jlSoundShutdown();
|
||||
|
||||
/*
|
||||
Load .jla Sound Bank into memory, or into DOC RAM
|
||||
*/
|
||||
jlSoundT jlSoundLoad(const char* pSoundBankPath);
|
||||
/*
|
||||
Load .jla Sound Bank from memory, into DOC RAM
|
||||
DO NOT FREE THIS MEMORY (pointers in the library will point into it)
|
||||
it may be free after the jlSoundFree hsa been called
|
||||
*/
|
||||
jlSoundT jlSoundLoadAt(const char* pBankInRAM);
|
||||
/*
|
||||
Returns back an index into the audio definition table, which is required
|
||||
in order to call jlSoundPlay
|
||||
*/
|
||||
signed short jlSoundFind(jlSoundT soundbank, const char* sfxName);
|
||||
/*
|
||||
Play a Sound
|
||||
*/
|
||||
void jlSoundPlay(jlSoundT soundbank, signed short audio_index);
|
||||
/*
|
||||
Return the number of SFX in this Bank
|
||||
*/
|
||||
signed short jlSoundGetNumSFX(jlSoundT soundbank);
|
||||
/*
|
||||
Return a C string name of the sound effect with this index
|
||||
DO NOT FREE THIS POINTER
|
||||
*/
|
||||
char *jlSoundGetName(signed short audio_index);
|
||||
/*
|
||||
Called when you are done with this soundbank
|
||||
*/
|
||||
void jlSoundFree(jlSoundT soundbank);
|
||||
|
||||
#endif /* JL_SOUND_H */
|
||||
|
||||
|
||||
|
Loading…
Add table
Reference in a new issue