| 389 | |
| 390 | |
| 391 | inline float atanHelper(float x) |
| 392 | { |
| 393 | float x2 = x * x; |
| 394 | return (((0.079331 * x2) - 0.288679) * x2 + 0.995354) * x; |
| 395 | |
| 396 | // an even more accurate alternative, less fast |
| 397 | // return ((((-0.0389929 * x2) + 0.1462766) * x2 - 0.3211819) * x2 + 0.9992150) * x; |
| 398 | } |
| 399 | |
| 400 | |
| 401 | float atan2Fast(float y, float x) |