- use value parameters for arguments in binaryangle.h.

This commit is contained in:
Christoph Oelckers 2021-03-24 09:02:07 +01:00
parent 087da46522
commit 829be9b56b

View file

@ -511,11 +511,11 @@ inline FSerializer &Serialize(FSerializer &arc, const char *key, fixedhoriz &obj
//
//---------------------------------------------------------------------------
inline double bradarangf(const double& vect)
inline double bradarangf(double vect)
{
return atan(vect) * BRadAngScale;
}
inline double bvectangf(const int32_t& x, const int32_t& y)
inline double bvectangf(int32_t x, int32_t y)
{
if ((x | y) == 0)
{
@ -546,15 +546,15 @@ inline double bvectangf(const int32_t& x, const int32_t& y)
return fmod(bradarangf(double(x) / -y) + 512 + ((y < 0) << 10), 2048.);
}
}
inline int32_t bvectang(const int32_t& x, const int32_t& y)
inline int32_t bvectang(int32_t x, int32_t y)
{
return xs_CRoundToInt(bvectangf(x, y));
}
inline fixed_t bvectangq16(const int32_t& x, const int32_t& y)
inline fixed_t bvectangq16(int32_t x, int32_t y)
{
return FloatToFixed(bvectangf(x, y));
}
inline binangle bvectangbam(const int32_t& x, const int32_t& y)
inline binangle bvectangbam(int32_t x, int32_t y)
{
return bamang(xs_CRoundToUInt(bvectangf(x, y) * BAMUNIT));
}