14 #define YI_SIN (float)sin 15 #define YI_COS (float)cos 16 #define YI_FPOW(x, y) pow((float)x, (float)y) 17 #define YI_SQRT(x) sqrt(x) 24 #define YI_ITOFXW(x) ((x) << 16) // Integer to fixed point 25 #define YI_FXTOIW(x) ((x) >> 16) // Fixed point to integer 26 #define YI_DIVFXW(x,y) ((y << 16) / (x)) // Divide a fixed by a fixed 27 #define YI_ITOFX(x) ((x) << 16) // Integer to fixed point 28 #define YI_FTOFX(x) (int32_t)((x)*65536) // Float to fixed point 29 #define YI_DTOFX(x) (int32_t)((x)*65536) // Double to fixed point 30 #define YI_FXTOI(x) ((x) >> 16) // Fixed point to integer 31 #define YI_FXTOF(x) ((float)(x) / 65536) // Fixed point to float 32 #define YI_FXTOD(x) ((double)(x) / 65536) // Fixed point to double 33 #define YI_MULFX(x,y) (((y) * (x)) >> 16) // Multiply a fixed by a fixed 34 #define YI_MULFX2(x,y) ((((y)>> 16) * ((x)>> 16))) // Multiply a fixed by a fixed 35 #define YI_DIVFX(x,y) (((x) << 16) / (y)) // Divide a fixed by a fixed 43 extern const float YI_PI;
54 #define YI_ABS(x) (((x) < 0) ? -(x) : (x)) 55 #define YI_FABS(x) (((x) < 0) ? -(x) : (x)) 56 #define YI_DABS(x) (((x) < 0) ? -(x) : (x)) 57 #define YI_SGN(x) (((x) > 0 ) ? 1 : ((x) < 0) ? -1 : 0) 58 #define YI_FSGN(x) (((x) > 0 ) ? 1 : ((x) < 0) ? -1 : 0) 59 #define YI_SGN2(x, y) (((x) > y ) ? 1 : ((x) < y) ? -1 : 0) 76 int32_t
Log2(int32_t a);
77 int32_t
Atan2i(int32_t y, int32_t x);
78 int32_t
AngleDiff(int32_t SrcAngle, int32_t TargetAngle);
81 int32_t
YI_POW(int32_t P, int32_t z);
const int32_t YI_ATAN_SIZE
Definition: YiMathTables.h:21
#define YI_SGN(x)
Definition: YiMath.h:57
int32_t YI_INTSQRT256(int32_t l2)
#define YI_EXTERNINLINE
Definition: YiPredef.h:74
const int32_t YI_ANGLE2PI
Definition: YiMathTables.h:15
YI_EXTERNINLINE int32_t YI_ROUND(float fval)
int32_t YI_INTSQRT(int32_t l2)
#define YI_DABS(x)
Definition: YiMath.h:56
#define YI_FSGN(x)
Definition: YiMath.h:58
const int16_t g_sYICosine[YI_ANGLE2PI]
Definition: YiMathTables.h:118
const float YI_PI
Definition: YiMathTables.h:18
YI_EXTERNINLINE int32_t YI_FLOOR(float fVal)
int32_t YI_POW(int32_t P, int32_t z)
YI_EXTERNINLINE int32_t YI_DIFF(int32_t x, int32_t y)
const int32_t YI_TRIG_SHIFT
Definition: YiMathTables.h:19
int32_t AngleDiff(int32_t SrcAngle, int32_t TargetAngle)
const int32_t YI_ANGLEMASK
Definition: YiMathTables.h:17
int32_t Atan2i(int32_t y, int32_t x)
const uint16_t g_usYIArctan[YI_ATAN_SIZE+1]
Definition: YiMathTables.h:213
const int32_t YI_TRIG_MUL
Definition: YiMathTables.h:20
const int32_t YI_ANGLESHIFT
Definition: YiMathTables.h:14
#define YI_FABS(x)
Definition: YiMath.h:55
#define YI_ABS(x)
Definition: YiMath.h:54
YI_EXTERNINLINE int32_t YI_CEIL(float fVal)
#define YI_SGN2(x, y)
Definition: YiMath.h:59
const int16_t g_sYISine[YI_ANGLE2PI]
Definition: YiMathTables.h:23
const uint16_t g_usYISqrt[256 *16]
Definition: YiMathTables.h:238