@@ -114,9 +114,9 @@ namespace oxygine
}
- spSoundInstance SoundPlayer::play(Resource* res, const PlayOptions& opt)
+ spSoundInstance SoundPlayer::play(const Resource* res, const PlayOptions& opt)
{
- ResSound* ressound = safeCast<ResSound*>(res);
+ const ResSound* ressound = safeCast<const ResSound*>(res);
if (!ressound || !ressound->getSound())
return 0;
@@ -56,7 +56,7 @@ namespace oxygine
~SoundPlayer();
- spSoundInstance play(Resource*, const PlayOptions& = PlayOptions());
+ spSoundInstance play(const Resource*, const PlayOptions& = PlayOptions());
spSoundInstance play(Sound*, const PlayOptions& = PlayOptions());
spSoundInstance play(const std::string& id, const PlayOptions& = PlayOptions());
@@ -28,6 +28,9 @@ namespace oxygine
alSourcef(_alSource, AL_PITCH, _pitch);
OAL_CHECK();
+
+ alSource3f(_alSource, AL_POSITION, _pos3d.x, _pos3d.y, _pos3d.z);
+ OAL_CHECK();
void SoundHandleOAL::_play()