aboutsummaryrefslogtreecommitdiffstats
path: root/al
diff options
context:
space:
mode:
authorBoris I. Bendovsky <[email protected]>2022-07-14 21:25:36 +0300
committerBoris I. Bendovsky <[email protected]>2022-07-17 20:59:05 +0300
commit74c923edcebc5e6b4931ccf47b8292d828df653c (patch)
tree6b4675cae023b6cc30d496fc7d081d34ef6f8b8e /al
parent8de2a560688fb9da8a9d7be4344b4fc5245a2da5 (diff)
[EAX_FX_SLOT] Fix slot's occlusion contribution
Diffstat (limited to 'al')
-rw-r--r--al/source.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/al/source.cpp b/al/source.cpp
index e5241a39..3bf65586 100644
--- a/al/source.cpp
+++ b/al/source.cpp
@@ -4049,6 +4049,7 @@ EaxAlLowPassParam ALsource::eax_create_room_filter_param(
const auto& fx_slot_eax = fx_slot.eax_get_eax_fx_slot();
const auto gain_mb =
+ (static_cast<float>(fx_slot_eax.lOcclusion) * fx_slot_eax.flOcclusionLFRatio) +
static_cast<float>(eax_.source.lRoom + send.lSend) +
eax_calculate_dst_occlusion_mb(
eax_.source.lOcclusion,
@@ -4062,8 +4063,9 @@ EaxAlLowPassParam ALsource::eax_create_room_filter_param(
(static_cast<float>(send.lExclusion) * send.flExclusionLFRatio);
const auto gain_hf_mb =
+ static_cast<float>(fx_slot_eax.lOcclusion) +
static_cast<float>(eax_.source.lRoomHF + send.lSendHF) +
- (static_cast<float>(fx_slot_eax.lOcclusion + eax_.source.lOcclusion) * eax_.source.flOcclusionRoomRatio) +
+ (static_cast<float>(eax_.source.lOcclusion) * eax_.source.flOcclusionRoomRatio) +
(static_cast<float>(send.lOcclusion) * send.flOcclusionRoomRatio) +
static_cast<float>(eax_.source.lExclusion + send.lExclusion);