25 lines
441 B
C
25 lines
441 B
C
#ifndef MUSIC_H
|
|
#define MUSIC_H
|
|
#include <SDL2/SDL_mixer.h>
|
|
|
|
struct Music {
|
|
char *name;
|
|
Mix_Music *music;
|
|
};
|
|
struct Music *loadMusic(const char *name);
|
|
void freeMusic(struct Music *music);
|
|
int playMusic(struct Music *music);
|
|
int stopMusic();
|
|
|
|
struct Sound {
|
|
char *name;
|
|
Mix_Chunk *sound;
|
|
};
|
|
struct Sound *loadSound(const char *name);
|
|
void freeSound(struct Sound *sound);
|
|
int playSound(struct Sound *sound);
|
|
int stopSound();
|
|
|
|
|
|
#endif
|