1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-09 12:42:11 +00:00
OpenMW/apps/openmw/mwsound/sound_output.hpp

42 lines
1.3 KiB
C++
Raw Normal View History

#ifndef GAME_SOUND_SOUND_OUTPUT_H
#define GAME_SOUND_SOUND_OUTPUT_H
#include <string>
2012-03-17 09:55:08 +00:00
#include <memory>
2012-03-17 13:51:44 +00:00
#include "../mwworld/ptr.hpp"
namespace MWSound
{
class SoundManager;
2012-03-17 09:55:08 +00:00
class Sound_Decoder;
class Sound;
class Sound_Output
{
SoundManager &mManager;
virtual std::vector<std::string> enumerate() = 0;
2012-03-18 19:19:54 +00:00
virtual void init(const std::string &devname="") = 0;
virtual void deinit() = 0;
virtual Sound *playSound(const std::string &fname, float volume, float pitch, bool loop) = 0;
virtual Sound *playSound3D(const std::string &fname, const float *pos, float volume, float pitch,
2012-03-17 13:51:44 +00:00
float min, float max, bool loop) = 0;
virtual Sound *streamSound(const std::string &fname, float volume, float pitch) = 0;
2012-03-19 14:28:03 +00:00
virtual Sound *streamSound3D(const std::string &fname, const float *pos, float volume, float pitch,
float min, float max) = 0;
2012-03-17 09:55:08 +00:00
virtual void updateListener(const float *pos, const float *atdir, const float *updir) = 0;
Sound_Output(SoundManager &mgr) : mManager(mgr) { }
public:
virtual ~Sound_Output() { }
friend class OpenAL_Output;
friend class SoundManager;
};
}
#endif