ML_math.h File Reference
This file contains math headers.
More...
Functions |
float | ML_Distance (s32 x1, s32 y1, s32 x2, s32 y2) |
| This function calculates the squared distance between two points.
|
float | ML_TrueDistance (s32 x1, s32 y1, s32 x2, s32 y2) |
| This function calculates the distance between two points. (much slower than ML_Distance).
|
Detailed Description
This file contains math headers.
Function Documentation
float ML_Distance |
( |
s32 |
x1, |
|
|
s32 |
y1, |
|
|
s32 |
x2, |
|
|
s32 |
y2 | |
|
) |
| | |
This function calculates the squared distance between two points.
- Parameters:
-
| x1 | X position of the first point |
| y1 | Y position of the first point |
| x2 | X position of the second point |
| y2 | Y position of the second point |
- Returns:
- squared distance between the two points
float ML_TrueDistance |
( |
s32 |
x1, |
|
|
s32 |
y1, |
|
|
s32 |
x2, |
|
|
s32 |
y2 | |
|
) |
| | |
This function calculates the distance between two points. (much slower than ML_Distance).
- Parameters:
-
| x1 | X position of the first point |
| y1 | Y position of the first point |
| x2 | X position of the second point |
| y2 | Y position of the second point |
- Returns:
- distance between the two points