aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2010-01-11 05:37:20 -0800
committerChris Robinson <[email protected]>2010-01-11 05:37:20 -0800
commit705849ca7371176d4e645b92898cb9a235602f9f (patch)
treebd6f3825bc2f84d1dff371a73c4e36baeafd2d26 /OpenAL32
parent1a57f095e8970f11edccd6f122b7a87391b04166 (diff)
Add an option for point resampling
Diffstat (limited to 'OpenAL32')
-rw-r--r--OpenAL32/Include/alSource.h10
-rw-r--r--OpenAL32/alSource.c2
2 files changed, 12 insertions, 0 deletions
diff --git a/OpenAL32/Include/alSource.h b/OpenAL32/Include/alSource.h
index 3889c85c..de746c61 100644
--- a/OpenAL32/Include/alSource.h
+++ b/OpenAL32/Include/alSource.h
@@ -22,6 +22,14 @@
extern "C" {
#endif
+typedef enum {
+ POINT = 0,
+ LINEAR,
+
+ RESAMPLER_MAX
+} resampler_t;
+extern resampler_t DefaultResampler;
+
typedef struct ALbufferlistitem
{
struct ALbuffer *buffer;
@@ -47,6 +55,8 @@ typedef struct ALsource
ALboolean bLooping;
ALenum DistanceModel;
+ resampler_t Resampler;
+
ALenum state;
ALuint position;
ALuint position_fraction;
diff --git a/OpenAL32/alSource.c b/OpenAL32/alSource.c
index 5ffc503c..5ad255d6 100644
--- a/OpenAL32/alSource.c
+++ b/OpenAL32/alSource.c
@@ -1818,6 +1818,8 @@ static ALvoid InitSourceParams(ALsource *pSource)
pSource->DistanceModel = AL_INVERSE_DISTANCE_CLAMPED;
+ pSource->Resampler = DefaultResampler;
+
pSource->state = AL_INITIAL;
pSource->lSourceType = AL_UNDETERMINED;