mirror of
https://github.com/lightsoutgames/bevy_openal.git
synced 2024-11-23 09:45:56 +00:00
Use locals, rather than matrices, to compute forward/up vectors.
This commit is contained in:
parent
69dc601029
commit
5982c63416
|
@ -327,9 +327,8 @@ fn listener_update(
|
||||||
})
|
})
|
||||||
.or_else(|| transform.cloned());
|
.or_else(|| transform.cloned());
|
||||||
if let Some(transform) = transform {
|
if let Some(transform) = transform {
|
||||||
let matrix = transform.compute_matrix().inverse();
|
let look = transform.local_x();
|
||||||
let look = matrix.x_axis;
|
let up = transform.local_z();
|
||||||
let up = matrix.z_axis;
|
|
||||||
context
|
context
|
||||||
.set_position([
|
.set_position([
|
||||||
transform.translation.x,
|
transform.translation.x,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user