Fix a couple comments about coordinate handedness

This commit is contained in:
Chris Robinson
2018-03-24 07:02:27 -07:00
parent 6d8062a2a7
commit 413d55aaa5
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -1073,9 +1073,9 @@ static aluMatrixf GetTransformFromVector(const ALfloat *vec)
/* Normalize the panning vector according to the N3D scale, which has an
* extra sqrt(3) term on the directional components. Converting from OpenAL
* to B-Format also requires negating X (ACN 1) and Z (ACN 3). Note however
* that the reverb panning vectors use right-handed coordinates, unlike the
* rest of OpenAL which use left-handed. This is fixed by negating Z, which
* cancels out with the B-Format Z negation.
* that the reverb panning vectors use left-handed coordinates, unlike the
* rest of OpenAL which use right-handed. This is fixed by negating Z,
* which cancels out with the B-Format Z negation.
*/
mag = sqrtf(vec[0]*vec[0] + vec[1]*vec[1] + vec[2]*vec[2]);
if(mag > 1.0f)
+1 -1
View File
@@ -281,7 +281,7 @@ static void UpdateListenerAndEffects(float timediff, const ALuint slots[2], cons
/* Calculate local_dir, which represents the listener-relative point to the
* adjacent zone (should also include orientation). Because EAX Reverb uses
* right-handed coordinates instead of left-handed like the rest of OpenAL,
* left-handed coordinates instead of right-handed like the rest of OpenAL,
* negate Z for the local values.
*/
local_dir[0] = portal_pos[0] - listener_pos[0];