19#ifndef HEADER_SFX_OPENAL_HPP
20#define HEADER_SFX_OPENAL_HPP
27#include "audio/sfx_base.hpp"
28#include "utils/leak_check.hpp"
29#include "utils/cpp2011.hpp"
44 ALuint m_sound_source;
47 std::atomic<SFXStatus> m_status;
77 SFXOpenAL(
SFXBuffer* buffer,
bool positional,
float volume,
78 bool owns_buffer = false);
81 virtual
void updatePlayingSFX(
float dt) OVERRIDE;
82 virtual
bool init() OVERRIDE;
83 virtual
void play() OVERRIDE;
84 virtual
void reallyPlayNow(
SFXBuffer* buffer = NULL) OVERRIDE;
85 virtual
void play(const
Vec3 &xyz,
SFXBuffer* buffer = NULL) OVERRIDE;
86 virtual
void reallyPlayNow(const
Vec3 &xyz,
SFXBuffer* buffer = NULL) OVERRIDE;
87 virtual
void setLoop(
bool status) OVERRIDE;
88 virtual
void reallySetLoop(
bool status) OVERRIDE;
89 virtual
void stop() OVERRIDE;
90 virtual
void reallyStopNow() OVERRIDE;
91 virtual
void pause() OVERRIDE;
92 virtual
void reallyPauseNow() OVERRIDE;
93 virtual
void resume() OVERRIDE;
94 virtual
void reallyResumeNow() OVERRIDE;
95 virtual
void deleteSFX() OVERRIDE;
96 virtual
void setSpeed(
float factor) OVERRIDE;
97 virtual
void reallySetSpeed(
float factor) OVERRIDE;
98 virtual
void setPosition(const
Vec3 &position) OVERRIDE;
99 virtual
void reallySetPosition(const
Vec3 &p) OVERRIDE;
100 virtual
void setSpeedPosition(
float factor, const
Vec3 &p) OVERRIDE;
101 virtual
void reallySetSpeedPosition(
float f,const
Vec3 &p) OVERRIDE;
102 virtual
void setVolume(
float volume) OVERRIDE;
103 virtual
void reallySetVolume(
float volume) OVERRIDE;
104 virtual
void setMasterVolume(
float volume) OVERRIDE;
105 virtual
void reallySetMasterVolumeNow(
float volue) OVERRIDE;
106 virtual
void onSoundEnabledBack() OVERRIDE;
107 virtual
void setRolloff(
float rolloff) OVERRIDE;
110 virtual
bool isLooped() OVERRIDE {
return m_loop; }
113 virtual SFXStatus getStatus() OVERRIDE {
return m_status; }
117 virtual SFXBuffer* getBuffer() const OVERRIDE
118 {
return m_sound_buffer; }
The base class for sound effects.
Definition: sfx_base.hpp:43
The buffer (data) for one kind of sound effects.
Definition: sfx_buffer.hpp:44
A wrapper around bullets btVector3 to include conventient conversion functions (e....
Definition: vec3.hpp:35