aboutsummaryrefslogtreecommitdiffstats
path: root/alc/effects/dedicated.cpp
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2023-12-24 02:48:20 -0800
committerChris Robinson <[email protected]>2023-12-24 02:48:20 -0800
commitdae225e88dbf795e776a2c9f2dbe5bb07c2228b9 (patch)
tree8a2e79a24fef5a99b3d0f883ab03cc070a2b584a /alc/effects/dedicated.cpp
parent29a1001a22891294ab63102e8868bdea52eb7b93 (diff)
Rework effect property handling
To nake EffectProps a variant instead of a union, and avoid manual vtables.
Diffstat (limited to 'alc/effects/dedicated.cpp')
-rw-r--r--alc/effects/dedicated.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/alc/effects/dedicated.cpp b/alc/effects/dedicated.cpp
index 1629aaea..23ac4d1a 100644
--- a/alc/effects/dedicated.cpp
+++ b/alc/effects/dedicated.cpp
@@ -73,7 +73,7 @@ void DedicatedState::update(const ContextBase*, const EffectSlot *slot,
{
std::fill(mTargetGains.begin(), mTargetGains.end(), 0.0f);
- const float Gain{slot->Gain * props->DedicatedDialog.Gain};
+ const float Gain{slot->Gain * std::get<DedicatedDialogProps>(*props).Gain};
/* Dialog goes to the front-center speaker if it exists, otherwise it plays
* from the front-center location.
@@ -99,7 +99,7 @@ void DedicatedLfeState::update(const ContextBase*, const EffectSlot *slot,
{
std::fill(mTargetGains.begin(), mTargetGains.end(), 0.0f);
- const float Gain{slot->Gain * props->DedicatedLfe.Gain};
+ const float Gain{slot->Gain * std::get<DedicatedLfeProps>(*props).Gain};
const size_t idx{target.RealOut ? target.RealOut->ChannelIndex[LFE] : InvalidChannelIndex};
if(idx != InvalidChannelIndex)