diff options
Diffstat (limited to 'OpenAL32/Include')
-rw-r--r-- | OpenAL32/Include/alListener.h | 19 | ||||
-rw-r--r-- | OpenAL32/Include/alMain.h | 5 | ||||
-rw-r--r-- | OpenAL32/Include/alu.h | 2 |
3 files changed, 18 insertions, 8 deletions
diff --git a/OpenAL32/Include/alListener.h b/OpenAL32/Include/alListener.h index eb386f7f..ae66b0e3 100644 --- a/OpenAL32/Include/alListener.h +++ b/OpenAL32/Include/alListener.h @@ -8,19 +8,23 @@ extern "C" { #endif +struct ALcontextProps { + ALfloat DopplerFactor; + ALfloat DopplerVelocity; + ALfloat SpeedOfSound; + ALboolean SourceDistanceModel; + enum DistanceModel DistanceModel; + ALfloat MetersPerUnit; + + ATOMIC(struct ALcontextProps*) next; +}; + struct ALlistenerProps { ALfloat Position[3]; ALfloat Velocity[3]; ALfloat Forward[3]; ALfloat Up[3]; ALfloat Gain; - ALfloat MetersPerUnit; - - ALfloat DopplerFactor; - ALfloat DopplerVelocity; - ALfloat SpeedOfSound; - ALboolean SourceDistanceModel; - enum DistanceModel DistanceModel; ATOMIC(struct ALlistenerProps*) next; }; @@ -31,7 +35,6 @@ typedef struct ALlistener { ALfloat Forward[3]; ALfloat Up[3]; ALfloat Gain; - ALfloat MetersPerUnit; /* Pointer to the most recent property values that are awaiting an update. */ diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h index 614c3b43..95137972 100644 --- a/OpenAL32/Include/alMain.h +++ b/OpenAL32/Include/alMain.h @@ -382,6 +382,7 @@ struct Hrtf; struct HrtfEntry; struct FrontStablizer; struct Compressor; +struct ALcontextProps; #define DEFAULT_OUTPUT_RATE (44100) @@ -851,6 +852,7 @@ struct ALCcontext_struct { ALfloat DopplerFactor; ALfloat DopplerVelocity; ALfloat SpeedOfSound; + ALfloat MetersPerUnit; ATOMIC(ALenum) DeferUpdates; RWLock PropLock; @@ -863,6 +865,9 @@ struct ALCcontext_struct { ALfloat GainBoost; + ATOMIC(struct ALcontextProps*) Update; + ATOMIC(struct ALcontextProps*) FreeList; + struct ALvoice **Voices; ALsizei VoiceCount; ALsizei MaxVoices; diff --git a/OpenAL32/Include/alu.h b/OpenAL32/Include/alu.h index 1295fee3..2344cc6d 100644 --- a/OpenAL32/Include/alu.h +++ b/OpenAL32/Include/alu.h @@ -514,6 +514,8 @@ void aluMixData(ALCdevice *device, ALvoid *OutBuffer, ALsizei NumSamples); /* Caller must lock the device. */ void aluHandleDisconnect(ALCdevice *device); +void UpdateContextProps(ALCcontext *context); + extern ALfloat ConeScale; extern ALfloat ZScale; extern ALboolean OverrideReverbSpeedOfSound; |