mirror of
https://github.com/encounter/bfbb.git
synced 2026-03-30 10:58:00 -07:00
1acbd170b9
* Set max compiler/linker errors to 1 * Add inspect back in * decomp
69 lines
1.2 KiB
Plaintext
69 lines
1.2 KiB
Plaintext
#ifndef _MSL_CMATH
|
|
#define _MSL_CMATH
|
|
|
|
#include <math.h>
|
|
|
|
namespace std
|
|
{
|
|
// TODO: fix inline function ordering
|
|
|
|
#ifndef INLINE
|
|
float atan2f(float y, float x);
|
|
float sinf(float x);
|
|
float cosf(float x);
|
|
float tanf(float x);
|
|
float ceilf(float x);
|
|
float asinf(float x);
|
|
float acosf(float x);
|
|
float expf(float x);
|
|
float floorf(float x);
|
|
#else
|
|
inline float atan2f(float y, float x)
|
|
{
|
|
return (float)atan2((double)y, (double)x);
|
|
}
|
|
|
|
inline float sinf(float x)
|
|
{
|
|
return (float)sin((double)x);
|
|
}
|
|
|
|
inline float cosf(float x)
|
|
{
|
|
return (float)cos((double)x);
|
|
}
|
|
|
|
inline float tanf(float x)
|
|
{
|
|
return (float)tan((double)x);
|
|
}
|
|
|
|
inline float ceilf(float x)
|
|
{
|
|
return (float)ceil((double)x);
|
|
}
|
|
|
|
inline float asinf(float x)
|
|
{
|
|
return (float)asin((double)x);
|
|
}
|
|
|
|
inline float acosf(float x)
|
|
{
|
|
return (float)acos((double)x);
|
|
}
|
|
|
|
inline float expf(float x)
|
|
{
|
|
return (float)exp((double)x);
|
|
}
|
|
|
|
inline float floorf(float x)
|
|
{
|
|
return (float)floor((double)x);
|
|
}
|
|
#endif
|
|
} // namespace std
|
|
|
|
#endif
|