aboutsummaryrefslogtreecommitdiffstats
path: root/al
diff options
context:
space:
mode:
Diffstat (limited to 'al')
-rw-r--r--al/auxeffectslot.cpp4
-rw-r--r--al/source.cpp41
2 files changed, 9 insertions, 36 deletions
diff --git a/al/auxeffectslot.cpp b/al/auxeffectslot.cpp
index 3e755569..dc6e1cfb 100644
--- a/al/auxeffectslot.cpp
+++ b/al/auxeffectslot.cpp
@@ -1013,10 +1013,6 @@ void ALeffectslot::updateProps(ALCcontext *context)
void UpdateAllEffectSlotProps(ALCcontext *context)
{
std::lock_guard<std::mutex> _{context->mEffectSlotLock};
-#ifdef ALSOFT_EAX
- if(context->has_eax())
- context->eax_commit_fx_slots();
-#endif
for(auto &sublist : context->mEffectSlotList)
{
uint64_t usemask{~sublist.FreeMask};
diff --git a/al/source.cpp b/al/source.cpp
index eb45bf9c..f6358607 100644
--- a/al/source.cpp
+++ b/al/source.cpp
@@ -3919,41 +3919,18 @@ ALsource::~ALsource()
void UpdateAllSourceProps(ALCcontext *context)
{
std::lock_guard<std::mutex> _{context->mSourceLock};
-#ifdef ALSOFT_EAX
- if(context->has_eax())
- {
- /* If EAX is enabled, we need to go through and commit all sources' EAX
- * changes, along with updating its voice, if any.
- */
- for(auto &sublist : context->mSourceList)
- {
- uint64_t usemask{~sublist.FreeMask};
- while(usemask)
- {
- const int idx{al::countr_zero(usemask)};
- usemask &= ~(1_u64 << idx);
-
- ALsource *source{sublist.Sources + idx};
- source->eax_commit_and_update();
- }
- }
- }
- else
-#endif
+ auto voicelist = context->getVoicesSpan();
+ ALuint vidx{0u};
+ for(Voice *voice : voicelist)
{
- auto voicelist = context->getVoicesSpan();
- ALuint vidx{0u};
- for(Voice *voice : voicelist)
+ ALuint sid{voice->mSourceID.load(std::memory_order_acquire)};
+ ALsource *source = sid ? LookupSource(context, sid) : nullptr;
+ if(source && source->VoiceIdx == vidx)
{
- ALuint sid{voice->mSourceID.load(std::memory_order_acquire)};
- ALsource *source = sid ? LookupSource(context, sid) : nullptr;
- if(source && source->VoiceIdx == vidx)
- {
- if(std::exchange(source->mPropsDirty, false))
- UpdateSourceProps(source, voice, context);
- }
- ++vidx;
+ if(std::exchange(source->mPropsDirty, false))
+ UpdateSourceProps(source, voice, context);
}
+ ++vidx;
}
}