From 0b9fc03545f7418be89bb9a8901b342ce84a5f67 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Fri, 15 Jul 2022 04:28:13 -0700 Subject: Dynamically allocate EffectSlot objects --- al/source.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'al/source.cpp') diff --git a/al/source.cpp b/al/source.cpp index 88eeba99..e5241a39 100644 --- a/al/source.cpp +++ b/al/source.cpp @@ -160,7 +160,7 @@ void UpdateSourceProps(const ALsource *source, Voice *voice, ALCcontext *context auto copy_send = [](const ALsource::SendData &srcsend) noexcept -> VoiceProps::SendData { VoiceProps::SendData ret{}; - ret.Slot = srcsend.Slot ? &srcsend.Slot->mSlot : nullptr; + ret.Slot = srcsend.Slot ? srcsend.Slot->mSlot : nullptr; ret.Gain = srcsend.Gain; ret.GainHF = srcsend.GainHF; ret.HFReference = srcsend.HFReference; @@ -170,7 +170,7 @@ void UpdateSourceProps(const ALsource *source, Voice *voice, ALCcontext *context }; std::transform(source->Send.cbegin(), source->Send.cend(), props->Send, copy_send); if(!props->Send[0].Slot && context->mDefaultSlot) - props->Send[0].Slot = &context->mDefaultSlot->mSlot; + props->Send[0].Slot = context->mDefaultSlot->mSlot; /* Set the new container for updating internal parameters. */ props = voice->mUpdate.exchange(props, std::memory_order_acq_rel); -- cgit v1.2.3