Files
devilutionX/SourceS/soundsample.h
T
Anders Jenbo 88a715cdcc Clean up narator sound logic
Also this provides a helper function for calculating the length of a
sound
2021-01-24 07:08:11 +01:00

20 lines
347 B
C++

#pragma once
#include <SDL_mixer.h>
namespace dvl {
typedef struct SoundSample final {
public:
void Release();
bool IsPlaying();
void Play(int lVolume, int lPan, int channel = -1);
void Stop();
int SetChunk(BYTE *fileData, DWORD dwBytes);
int GetLength();
private:
Mix_Chunk *chunk;
} SoundSample;
} // namespace dvl