| /TwlSDK-5.4/build/libraries/fx/common/src/ |
| D | fx_sincos.c | 22 fx16 FX_SinCosTable_[4096 * 2]; 26 const fx16 FX_SinCosTable_[4096 * 2] = { 27 (fx16)0x0000, (fx16)0x1000, // 0.000, 1.000 ( deg = 0.000000 ) 28 (fx16)0x0006, (fx16)0x1000, // 0.001, 1.000 ( deg = 0.087891 ) 29 (fx16)0x000d, (fx16)0x1000, // 0.003, 1.000 ( deg = 0.175781 ) 30 (fx16)0x0013, (fx16)0x1000, // 0.005, 1.000 ( deg = 0.263672 ) 31 (fx16)0x0019, (fx16)0x1000, // 0.006, 1.000 ( deg = 0.351562 ) 32 (fx16)0x001f, (fx16)0x1000, // 0.008, 1.000 ( deg = 0.439453 ) 33 (fx16)0x0026, (fx16)0x1000, // 0.009, 1.000 ( deg = 0.527344 ) 34 (fx16)0x002c, (fx16)0x1000, // 0.011, 1.000 ( deg = 0.615234 ) [all …]
|
| D | fx_atan.c | 28 const fx16 FX_AtanTable_[128 + 1] = { 29 (fx16)0x0000, // 0.000 30 (fx16)0x0020, // 0.008 31 (fx16)0x0040, // 0.016 32 (fx16)0x0060, // 0.023 33 (fx16)0x0080, // 0.031 34 (fx16)0x00a0, // 0.039 35 (fx16)0x00c0, // 0.047 36 (fx16)0x00e0, // 0.055 37 (fx16)0x0100, // 0.062 [all …]
|
| D | fx.c | 54 SDK_ASSERT(2 == sizeof(fx16)); in FX_Init() 74 fx16 s; in FX_Init() 81 s = (fx16)((ss + 0x80000LL) >> 20); in FX_Init() 85 FX_SinCosTable_[SDK_FX_INIT_2PI - i * 2] = (fx16)-s; // sin: 0 to -pi/2 in FX_Init() 87 FX_SinCosTable_[SDK_FX_INIT_PI + i * 2] = (fx16)-s; // sin: -pi/2 to -pi in FX_Init() 104 fx16 s; in FX_Init() 108 s = (fx16)FX_F32_TO_FX32(sinf(rad)); in FX_Init() 111 FX_SinCosTable_[SDK_FX_INIT_2PI - i * 2] = (fx16)-s; // sin: 0 to -pi/2 in FX_Init() 113 FX_SinCosTable_[SDK_FX_INIT_PI + i * 2] = (fx16)-s; // sin: -pi/2 to -pi in FX_Init()
|
| D | fx_asinacosidx.c | 45 fx16 value; /* Search value */ in FX_AsinIdx() 63 value = (fx16)x; in FX_AsinIdx() 100 fx16 value; in FX_AcosIdx() 118 value = (fx16)x; in FX_AcosIdx()
|
| D | fx_vec.c | 93 ab->x = (fx16)(a->x + b->x); in VEC_Fx16Add() 94 ab->y = (fx16)(a->y + b->y); in VEC_Fx16Add() 95 ab->z = (fx16)(a->z + b->z); in VEC_Fx16Add() 117 ab->x = (fx16)(a->x - b->x); in VEC_Fx16Subtract() 118 ab->y = (fx16)(a->y - b->y); in VEC_Fx16Subtract() 119 ab->z = (fx16)(a->z - b->z); in VEC_Fx16Subtract() 225 axb->x = (fx16)x; in VEC_Fx16CrossProduct() 226 axb->y = (fx16)y; in VEC_Fx16CrossProduct() 227 axb->z = (fx16)z; in VEC_Fx16CrossProduct() 361 pDst->x = (fx16)((t * pSrc->x + (1LL << (32 + FX32_SHIFT))) >> (32 + FX32_SHIFT + 1)); in VEC_Fx16Normalize() [all …]
|
| /TwlSDK-5.4/build/demos/fx/test/src/ |
| D | table.c | 28 const fx16 testTable[4096 * 2] = { 29 (fx16)0x0000, (fx16)0x1000, // 0.000, 1.000 ( deg = 0.000000 ) 30 (fx16)0x0006, (fx16)0x1000, // 0.001, 1.000 ( deg = 0.087891 ) 31 (fx16)0x000d, (fx16)0x1000, // 0.003, 1.000 ( deg = 0.175781 ) 32 (fx16)0x0013, (fx16)0x1000, // 0.005, 1.000 ( deg = 0.263672 ) 33 (fx16)0x0019, (fx16)0x1000, // 0.006, 1.000 ( deg = 0.351562 ) 34 (fx16)0x001f, (fx16)0x1000, // 0.008, 1.000 ( deg = 0.439453 ) 35 (fx16)0x0026, (fx16)0x1000, // 0.009, 1.000 ( deg = 0.527344 ) 36 (fx16)0x002c, (fx16)0x1000, // 0.011, 1.000 ( deg = 0.615234 ) 37 (fx16)0x0032, (fx16)0x1000, // 0.012, 1.000 ( deg = 0.703125 ) [all …]
|
| /TwlSDK-5.4/include/nitro/gx/ |
| D | g3imm.h | 62 static void G3_Normal(fx16 x, fx16 y, fx16 z); 64 static void G3_Vtx(fx16 x, fx16 y, fx16 z); 65 static void G3_Vtx10(fx16 x, fx16 y, fx16 z); 66 static void G3_VtxXY(fx16 x, fx16 y); 67 static void G3_VtxXZ(fx16 x, fx16 z); 68 static void G3_VtxYZ(fx16 y, fx16 z); 69 static void G3_VtxDiff(fx16 x, fx16 y, fx16 z); 80 static void G3_LightVector(GXLightId lightID, fx16 x, fx16 y, fx16 z); 88 static void G3_PositionTest(fx16 x, fx16 y, fx16 z); 89 static void G3_VectorTest(fx16 x, fx16 y, fx16 z); [all …]
|
| D | g3c.h | 70 static void G3CS_Normal(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 72 static void G3CS_Vtx(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 73 static void G3CS_Vtx10(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 74 static void G3CS_VtxXY(GXDLInfo *info, fx16 x, fx16 y); 75 static void G3CS_VtxXZ(GXDLInfo *info, fx16 x, fx16 z); 76 static void G3CS_VtxYZ(GXDLInfo *info, fx16 y, fx16 z); 77 static void G3CS_VtxDiff(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 91 static void G3CS_LightVector(GXDLInfo *info, GXLightId lightID, fx16 x, fx16 y, fx16 z); 99 static void G3CS_PositionTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 100 static void G3CS_VectorTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z); [all …]
|
| D | g3b.h | 77 static void G3BS_Normal(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 79 static void G3BS_Vtx(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 80 static void G3BS_Vtx10(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 81 static void G3BS_VtxXY(GXDLInfo *info, fx16 x, fx16 y); 82 static void G3BS_VtxXZ(GXDLInfo *info, fx16 x, fx16 z); 83 static void G3BS_VtxYZ(GXDLInfo *info, fx16 y, fx16 z); 84 static void G3BS_VtxDiff(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 98 static void G3BS_LightVector(GXDLInfo *info, GXLightId lightID, fx16 x, fx16 y, fx16 z); 106 static void G3BS_PositionTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z); 107 static void G3BS_VectorTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z); [all …]
|
| /TwlSDK-5.4/include/nitro/math/ |
| D | fft.h | 46 void MATH_MakeFFTSinTable(fx16 *sinTable, u32 nShift); 60 void MATHi_FFT(fx32 *data, u32 nShift, const fx16 *sinTable); 74 void MATHi_IFFT(fx32 *data, u32 nShift, const fx16 *sinTable); 88 void MATH_FFT(fx32 *data, u32 nShift, const fx16 *sinTable); 102 void MATH_IFFT(fx32 *data, u32 nShift, const fx16 *sinTable); 116 void MATH_FFTReal(fx32 *data, u32 nShift, const fx16 *sinTable, const fx16 *sinTable2); 130 void MATH_IFFTReal(fx32 *data, u32 nShift, const fx16 *sinTable, const fx16 *sinTable2);
|
| /TwlSDK-5.4/build/demos/wm/wep-1/src/ |
| D | graphics.c | 84 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 88 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 92 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 96 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 107 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad() 108 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad() 109 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad() 110 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad()
|
| /TwlSDK-5.4/build/demos/wm/dataShare-Model/src/ |
| D | graphics.c | 85 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 89 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 93 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 97 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DTexQuad() 108 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad() 109 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)(sy * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad() 110 G3_Vtx((fx16)((sx + width) * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad() 111 G3_Vtx((fx16)(sx * PSEUDO2D_ONE), (fx16)((sy + height) * PSEUDO2D_ONE), 0); in drawPseudo2DColorQuad()
|
| /TwlSDK-5.4/build/demos/gx/UnitTours/3D_Command_Pack/src/ |
| D | main.c | 77 G3_LightVector(GX_LIGHTID_0, 0, (fx16)-FX32_SQRT1_2, (fx16)-FX32_SQRT1_2); in TwlMain() 80 G3_LightVector(GX_LIGHTID_1, (fx16)-FX32_SQRT1_2, 0, (fx16)-FX32_SQRT1_2); in TwlMain() 83 G3_LightVector(GX_LIGHTID_2, 0, (fx16)FX32_SQRT1_2, (fx16)-FX32_SQRT1_2); in TwlMain() 86 G3_LightVector(GX_LIGHTID_3, (fx16)FX32_SQRT1_2, 0, (fx16)-FX32_SQRT1_2); in TwlMain() 97 fx16 s = FX_SinIdx(Rotate); in TwlMain() 98 fx16 c = FX_CosIdx(Rotate); in TwlMain()
|
| /TwlSDK-5.4/include/nitro/fx/ |
| D | fx_trig.h | 32 extern fx16 FX_SinCosTable_[]; 34 extern const fx16 FX_SinCosTable_[]; 52 SDK_DECL_INLINE fx16 FX_SinIdx(int idx); 53 SDK_DECL_INLINE fx16 FX_CosIdx(int idx); 58 fx16 FX_Atan(fx32 x); 59 fx16 FX_Atan2(fx32 y, fx32 x); 80 SDK_INLINE fx16 FX_SinIdx(int idx) in FX_SinIdx() 96 SDK_INLINE fx16 FX_CosIdx(int idx) in FX_CosIdx()
|
| D | fx.h | 113 typedef s16 fx16; typedef 123 #define FX16_MAX ((fx16)0x7fff) 125 #define FX16_MIN ((fx16)0x8000) 128 #define FX_F32_TO_FX16(x) ((fx16)(((x) > 0) ? \ 129 (fx16)((x) * (1 << FX16_SHIFT) + 0.5f ) : \ 130 (fx16)((x) * (1 << FX16_SHIFT) - 0.5f ))) 150 fx16 x; 151 fx16 y; 152 fx16 z;
|
| /TwlSDK-5.4/include/nitro/prc/ |
| D | algo_common.h | 94 fx16 *lineSegmentRatioToStrokeArray; 98 fx16 *strokeRatios; 116 fx16 *lineSegmentRatioToStrokeArray; 120 fx16 *strokeRatios; 161 fx16 *lineSegmentRatioToStrokeArray; 167 fx16 *strokeRatioArray; 181 fx16 *lineSegmentRatioToStrokeArray; 189 fx16 *strokeRatioArray;
|
| /TwlSDK-5.4/build/demos/math/fft-2/src/ |
| D | main.c | 98 fx16 index; 99 fx16 step; 138 static fx16 sinTable[FFT_N - FFT_N / 4]; 140 static fx16 sinTable2[(FFT_N - FFT_N / 4) / 2]; 368 osc.step = (fx16)FX_Div(GetFreq(tp.x * 12 + 60 * 64) << FX32_SHIFT, osc.rate); in NitroMain() 554 fx16 fsx = (fx16)(((sx - 128) * 0x1000) / 128); in DrawLine() 555 fx16 fsy = (fx16)(((96 - sy) * 0x1000) / 96); in DrawLine() 556 fx16 fex = (fx16)(((ex - 128) * 0x1000) / 128); in DrawLine() 557 fx16 fey = (fx16)(((96 - ey) * 0x1000) / 96); in DrawLine() 585 fx16 fsx = (fx16)(((sx - 128) * 0x1000) / 128); in DrawBar() [all …]
|
| /TwlSDK-5.4/build/demos/gx/UnitTours/RamOverFlow/src/ |
| D | main.c | 46 fx16 nx, ny, nz; in CircleVertex() 53 nx = (fx16)((x * 511) / length); in CircleVertex() 54 ny = (fx16)((y * 511) / length); in CircleVertex() 55 nz = (fx16)((z * 511) / length); in CircleVertex() 59 G3_Vtx((fx16)x, (fx16)y, (fx16)z); in CircleVertex() 226 fx16 s = FX_SinIdx(Rotate); in TwlMain() 227 fx16 c = FX_CosIdx(Rotate); in TwlMain()
|
| /TwlSDK-5.4/build/libraries/gx/ARM9/src/ |
| D | g3b.c | 735 void G3B_Normal(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3B_Normal() 774 void G3B_Vtx(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3B_Vtx() 794 void G3B_Vtx10(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3B_Vtx10() 814 void G3B_VtxXY(GXDLInfo *info, fx16 x, fx16 y) in G3B_VtxXY() 834 void G3B_VtxXZ(GXDLInfo *info, fx16 x, fx16 z) in G3B_VtxXZ() 854 void G3B_VtxYZ(GXDLInfo *info, fx16 y, fx16 z) in G3B_VtxYZ() 875 void G3B_VtxDiff(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3B_VtxDiff() 1015 void G3B_LightVector(GXDLInfo *info, GXLightId lightID, fx16 x, fx16 y, fx16 z) in G3B_LightVector() 1171 void G3B_PositionTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3B_PositionTest() 1193 void G3B_VectorTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3B_VectorTest()
|
| D | g3c.c | 898 void G3C_Normal(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3C_Normal() 937 void G3C_Vtx(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3C_Vtx() 957 void G3C_Vtx10(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3C_Vtx10() 977 void G3C_VtxXY(GXDLInfo *info, fx16 x, fx16 y) in G3C_VtxXY() 997 void G3C_VtxXZ(GXDLInfo *info, fx16 x, fx16 z) in G3C_VtxXZ() 1017 void G3C_VtxYZ(GXDLInfo *info, fx16 y, fx16 z) in G3C_VtxYZ() 1038 void G3C_VtxDiff(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3C_VtxDiff() 1176 void G3C_LightVector(GXDLInfo *info, GXLightId lightID, fx16 x, fx16 y, fx16 z) in G3C_LightVector() 1329 void G3C_PositionTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3C_PositionTest() 1350 void G3C_VectorTest(GXDLInfo *info, fx16 x, fx16 y, fx16 z) in G3C_VectorTest()
|
| /TwlSDK-5.4/build/demos/spi/spiMonkey/src/ |
| D | main.c | 248 fx16 fsx; in DrawLine() 249 fx16 fsy; in DrawLine() 250 fx16 fex; in DrawLine() 251 fx16 fey; in DrawLine() 253 fsx = (fx16)(((sx - 128) * 0x1000) / 128); in DrawLine() 254 fsy = (fx16)(((96 - sy) * 0x1000) / 96); in DrawLine() 255 fex = (fx16)(((ex - 128) * 0x1000) / 128); in DrawLine() 256 fey = (fx16)(((96 - ey) * 0x1000) / 96); in DrawLine()
|
| /TwlSDK-5.4/build/demos/gx/UnitTours/3D_Pol_Tex_Decal/src/ |
| D | main.c | 169 fx16 s = FX_SinIdx(Rotate); in TwlMain() 170 fx16 c = FX_CosIdx(Rotate); in TwlMain() 228 fx16 s = FX_SinIdx(Rotate); in TwlMain() 229 fx16 c = FX_CosIdx(Rotate); in TwlMain() 292 fx16 s = FX_SinIdx(Rotate); in TwlMain() 293 fx16 c = FX_CosIdx(Rotate); in TwlMain() 296 G3_RotZ((fx16)-s, c); in TwlMain()
|
| /TwlSDK-5.4/build/demos.TWL/dsp/snd-mic/src/ |
| D | main.c | 135 fx16 fsx = (fx16)(((cur - 128) * 0x1000) / 128); in DrawWaveGraph() 136 fx16 fsy = (fx16)(((96 - i) * 0x1000) / 96); in DrawWaveGraph() 137 fx16 fex = (fx16)(((nxt - 128) * 0x1000) / 128); in DrawWaveGraph() 138 fx16 fey = (fx16)(((96 - i + 1) * 0x1000) / 96); in DrawWaveGraph()
|
| /TwlSDK-5.4/build/demos/gx/UnitTours/PosVecTest/src/ |
| D | main.c | 259 fx16 s = FX_SinIdx(Rotate); in TwlMain() 260 fx16 c = FX_CosIdx(Rotate); in TwlMain() 297 fx16 vec[3]; in TwlMain() 299 fx16 s = FX_SinIdx(Rotate); in TwlMain() 300 fx16 c = FX_CosIdx(Rotate); in TwlMain() 352 fx16 s = FX_SinIdx(Rotate); in TwlMain() 353 fx16 c = FX_CosIdx(Rotate); in TwlMain()
|
| /TwlSDK-5.4/build/demos/gx/UnitTours/3D_Pol_Transparent/src/ |
| D | main.c | 105 fx16 s = FX_SinIdx(Rotate); in TwlMain() 106 fx16 c = FX_CosIdx(Rotate); in TwlMain() 157 fx16 s = FX_SinIdx(Rotate); in TwlMain() 158 fx16 c = FX_CosIdx(Rotate); in TwlMain()
|