diff options
author | kdx <kikoodx@paranoici.org> | 2023-04-30 16:37:46 +0200 |
---|---|---|
committer | kdx <kikoodx@paranoici.org> | 2023-04-30 16:37:46 +0200 |
commit | a4112e4311eb226c4f43cb697aa7f6c34bd7b9a5 (patch) | |
tree | fca5829693c41fac4bf2e70cd4c63f1d1742d51a /headers | |
parent | 6044a3bac4433e9ce8d114bdbc180ca7b48b2344 (diff) | |
download | tzr-a4112e4311eb226c4f43cb697aa7f6c34bd7b9a5.tar.gz |
music playing
Diffstat (limited to 'headers')
-rw-r--r-- | headers/TZR_globals.h | 1 | ||||
-rw-r--r-- | headers/TZR_sound.h | 5 | ||||
-rw-r--r-- | headers/TZR_types.h | 1 |
3 files changed, 7 insertions, 0 deletions
diff --git a/headers/TZR_globals.h b/headers/TZR_globals.h index 25919ad..cfedc43 100644 --- a/headers/TZR_globals.h +++ b/headers/TZR_globals.h @@ -23,3 +23,4 @@ extern TZR_KeyState ___tzr_mousestates[256]; extern float ___tzr_scale; extern int ___tzr_off_x; extern int ___tzr_off_y; +extern Mix_Music *___tzr_music; diff --git a/headers/TZR_sound.h b/headers/TZR_sound.h index b24823e..271995b 100644 --- a/headers/TZR_sound.h +++ b/headers/TZR_sound.h @@ -9,3 +9,8 @@ #endif #endif int _TZR_PlaySound(const TZR_PlaySoundArgs *args); + +/* Return -1 on error. */ +int TZR_PlayMusic(const char *path, int loop); + +void TZR_StopMusic(void); diff --git a/headers/TZR_types.h b/headers/TZR_types.h index 972c45e..b9ec3eb 100644 --- a/headers/TZR_types.h +++ b/headers/TZR_types.h @@ -41,6 +41,7 @@ typedef struct TZR_Sound TZR_Sound; typedef struct TZR_Resource TZR_Resource; typedef enum TZR_EventType TZR_EventType; typedef struct TZR_Event TZR_Event; +typedef struct TZR_Music TZR_Music; typedef struct TZR_DrawImageArgs TZR_DrawImageArgs; typedef struct TZR_DrawRectangleArgs TZR_DrawRectangleArgs; typedef struct TZR_PlaySoundArgs TZR_PlaySoundArgs; |