diff options
author | Devin Braune <[email protected]> | 2021-10-14 20:18:54 +0200 |
---|---|---|
committer | GitHub <[email protected]> | 2021-10-14 11:18:54 -0700 |
commit | 0e9ce1aa83b99058a4c1b75035f1a0102ff691ef (patch) | |
tree | f7d204147c89dacbaf4ade3195dd415695363259 | |
parent | 6a3c4c09f838b0e9156b3f4c223281a3ed43817b (diff) |
Fix cone angle calculation (#605)
-rw-r--r-- | alc/alu.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/alc/alu.cpp b/alc/alu.cpp index e28d2a53..b317a40f 100644 --- a/alc/alu.cpp +++ b/alc/alu.cpp @@ -1386,7 +1386,7 @@ void CalcAttnSourceParams(Voice *voice, const VoiceProps *props, const ContextBa /* Calculate directional soundcones */ if(directional && props->InnerAngle < 360.0f) { - const float Angle{Rad2Deg(std::acos(Direction.dot_product(ToSource)) * ConeScale * -2.0f)}; + const float Angle{Rad2Deg(std::acos(-Direction.dot_product(ToSource)) * ConeScale * 2.0f)}; float ConeGain, ConeHF; if(!(Angle > props->InnerAngle)) |