1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2024-11-25 17:53:47 +00:00
Commit graph

6 commits

Author SHA1 Message Date
fgenesis
cf6556b94d Implement stereo to mono mixing for proper L/R separation even for stereo samples.
This mixes only those sounds that are supposed to be played positional.
All centered (default) sounds are played in stereo, as usual.
2013-07-24 19:57:13 +02:00
fgenesis
e6680da428 Implemenet proper positional audio, one issue still.
With this patch, entities can serve as a sound source whose position
updates relative to the listener. This implements the last missing
feature of my previous positional audio patch, which is moving sound sources.
Previously, all sounds were relative to the listener with the listener
centered at (0, 0, 0), and once a sound started playing, the position could
not be changed. Volume was set as an estimation of the distance to the listener.

These restrictions are now gone; OpenAL will handle the volume & panning
based on the distance.

The remaining problem is that stereo sounds are not attenuated, at all.

Lua additions:
- playSfx() takes an additional parameter now.
- entity_setStopSoundsOnDeath()
2013-07-22 03:29:57 +02:00
fgenesis
66d3b90473 Fix two sound looping bugs.
The first one caused the music to stop randomly on scene changes,
reproducible by changing maps with different music while holding 'G'
button to speed up time.
For some reason this caused the music to stop playing during the crossfade.
Wasn't able to find the root cause, so I added a little hack to kick the
music back on track if it stops unexpectedly.

The second one was a simple string case issue; mostly noticable because of
map background sounds not playing in loop mode.
(this is possibly a regression from an earlier patch, not sure)
2012-10-07 00:05:17 +02:00
fgenesis
1fdae0c128 Replace #pragma once with #ifndef/#define pairs (to avoid warnings on gcc 2.95) 2012-09-23 04:51:13 +02:00
fgenesis
1ab32b585f Fixes for Linux
- fixed warning about PlaySfx::handle
- fixed displaying subtitles - if the path was not full lowercase it didn't find its txt files.
- CMake: removed SDLMAIN_FOUND, which is seemingly only defined on windows and does more harm than good.
- glpng: always use new libpng API (fixes windows build)
2012-01-10 19:34:31 +01:00
fgenesis
3096eaf5e2 initial commit. This is icculus version 5542b94cae02a6333845854bbbd1abe0a259f1a4 2011-08-03 22:05:33 +02:00