In lack of camera entity I created a Listener cube to test 3D sound. Works fine. Updates listener pos each tick.

This commit is contained in:
stiffly
2016-01-07 16:03:33 +01:00
parent d8c4c6e5ff
commit 2838446072
3 changed files with 25 additions and 9 deletions
+2 -2
View File
@@ -22,9 +22,9 @@ class SoundSystem
{
public:
SoundSystem() { }
SoundSystem(EventBroker* eventBroker);
SoundSystem(World* world, EventBroker* eventBroker);
~SoundSystem();
void Update() { } // Update emitters
void Update(); // Update emitters
private:
// Private setters and getters for working with glm
void setListenerPos(glm::vec3 pos) { alListener3f(AL_POSITION, pos.x, pos.y, pos.z); };