m
This commit is contained in:
1 parent
a03f74b125
commit
dfbeaf30ad
1 file changed
+7
-2
+7
-2
@@ -3,6 +3,7 @@
|
||||
// Copyright (C) 1993-1996 by id Software, Inc.
|
||||
// Copyright (C) 1998-2000 by DooM Legacy Team.
|
||||
// Copyright (C) 1999-2018 by Sonic Team Junior.
|
||||
// Copyright (C) 2009 by Stephen McGranahan.
|
||||
//
|
||||
// This program is free software distributed under the
|
||||
// terms of the GNU General Public License, version 2.
|
||||
@@ -406,9 +407,9 @@ void FV3_Rotate(vector3_t *rotVec, const vector3_t *axisVec, const angle_t angle
|
||||
rotVec->z = az+dz+ez;
|
||||
}
|
||||
|
||||
void FM_Rotate(matrix_t *dest, angle_t angle, fixed_t x, fixed_t y, fixed_t z)
|
||||
{
|
||||
#define M(row,col) dest->m[row * 4 + col]
|
||||
matrix_t *FM_Rotate(matrix_t *dest, angle_t angle, fixed_t x, fixed_t y, fixed_t z)
|
||||
{
|
||||
const fixed_t sinA = FINESINE(angle>>ANGLETOFINESHIFT);
|
||||
const fixed_t cosA = FINECOSINE(angle>>ANGLETOFINESHIFT);
|
||||
const fixed_t invCosA = FRACUNIT - cosA;
|
||||
@@ -458,5 +459,9 @@ void FM_Rotate(matrix_t *dest, angle_t angle, fixed_t x, fixed_t y, fixed_t z)
|
||||
M(1, 3) = 0;
|
||||
M(2, 3) = 0;
|
||||
M(3, 3) = FRACUNIT;
|
||||
|
||||
return dest;
|
||||
}
|
||||
|
||||
#undef M
|
||||
}
|
||||
Reference in new issue
Block a user