diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-05-03 19:36:07 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-03 19:36:07 +0200 |
commit | 1b2992799b324479b3fba9e05ae6226a46cb4143 (patch) | |
tree | dec0fb56da26538c10fb41824715c357b917e296 /scene/3d/audio_stream_player_3d.cpp | |
parent | 7d2e38d709834b3b880f9d17b591147b7976974a (diff) | |
parent | fa7a7795f09688b1c71ddad40243e46909989054 (diff) |
Merge pull request #60727 from aaronfranke/basis-axis-column
Diffstat (limited to 'scene/3d/audio_stream_player_3d.cpp')
-rw-r--r-- | scene/3d/audio_stream_player_3d.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/3d/audio_stream_player_3d.cpp b/scene/3d/audio_stream_player_3d.cpp index b17201f86b..f057c72012 100644 --- a/scene/3d/audio_stream_player_3d.cpp +++ b/scene/3d/audio_stream_player_3d.cpp @@ -447,7 +447,7 @@ Vector<AudioFrame> AudioStreamPlayer3D::_update_panning() { if (emission_angle_enabled) { Vector3 listenertopos = global_pos - listener_node->get_global_transform().origin; - float c = listenertopos.normalized().dot(get_global_transform().basis.get_axis(2).normalized()); //it's z negative + float c = listenertopos.normalized().dot(get_global_transform().basis.get_column(2).normalized()); //it's z negative float angle = Math::rad2deg(Math::acos(c)); if (angle > emission_angle) { db_att -= -emission_angle_filter_attenuation_db; |