diff options
Diffstat (limited to 'src/s_sound.h')
-rw-r--r-- | src/s_sound.h | 114 |
1 files changed, 0 insertions, 114 deletions
diff --git a/src/s_sound.h b/src/s_sound.h index 67071338..d2af9e88 100644 --- a/src/s_sound.h +++ b/src/s_sound.h @@ -31,120 +31,6 @@ #include "p_mobj.h" #include "sounds.h" -typedef enum -{ - SNDDEVICE_NONE = 0, - SNDDEVICE_PCSPEAKER = 1, - SNDDEVICE_ADLIB = 2, - SNDDEVICE_SB = 3, - SNDDEVICE_PAS = 4, - SNDDEVICE_GUS = 5, - SNDDEVICE_WAVEBLASTER = 6, - SNDDEVICE_SOUNDCANVAS = 7, - SNDDEVICE_GENMIDI = 8, - SNDDEVICE_AWE32 = 9, -} snddevice_t; - -// Interface for sound modules - -typedef struct -{ - // List of sound devices that this sound module is used for. - - snddevice_t *sound_devices; - int num_sound_devices; - - // Initialise sound module - // Returns true if successfully initialised - - boolean (*Init)(void); - - // Shutdown sound module - - void (*Shutdown)(void); - - // Returns the lump index of the given sound. - - int (*GetSfxLumpNum)(sfxinfo_t *sfxinfo); - - // Called periodically to update the subsystem. - - void (*Update)(void); - - // Update the sound settings on the given channel. - - void (*UpdateSoundParams)(int channel, int vol, int sep); - - // Start a sound on a given channel. Returns the channel id - // or -1 on failure. - - int (*StartSound)(int id, int channel, int vol, int sep); - - // Stop the sound playing on the given channel. - - void (*StopSound)(int channel); - - // Query if a sound is playing on the given channel - - boolean (*SoundIsPlaying)(int channel); - -} sound_module_t; - -// Interface for music modules - -typedef struct -{ - // List of sound devices that this music module is used for. - - snddevice_t *sound_devices; - int num_sound_devices; - - // Initialise the music subsystem - - boolean (*Init)(void); - - // Shutdown the music subsystem - - void (*Shutdown)(void); - - // Set music volume - range 0-127 - - void (*SetMusicVolume)(int volume); - - // Pause music - - void (*PauseMusic)(void); - - // Un-pause music - - void (*ResumeMusic)(void); - - // Register a song handle from data - // Returns a handle that can be used to play the song - - void *(*RegisterSong)(void *data, int len); - - // Un-register (free) song data - - void (*UnRegisterSong)(void *handle); - - // Play the song - - void (*PlaySong)(void *handle, int looping); - - // Stop playing the current song. - - void (*StopSong)(void); - - // Query if music is playing. - - boolean (*MusicIsPlaying)(void); -} music_module_t; - -extern int snd_sfxdevice; -extern int snd_musicdevice; -extern int snd_samplerate; - // // Initializes sound stuff, including volume // Sets channels, SFX and music volume, |