Util class for math operations.
More...
|
static void | calcAngleFaceToCamera (Point3 p1, Point3 p2, Point3 out) |
|
static float | metersToGlUnits (float meters) |
| Convert the meter units to the equivalent distance in the GL world. More...
|
|
static float | GLUnitsToMeters (float glUnits) |
|
static void | linearInterpolate (float x_start, float y_start, float z_start, float x_end, float y_end, float z_end, float newDistance, float totalDistanceToMove, Point3 dstPoint) |
| Calculate the point between two points according to a given distance. More...
|
|
static void | linearInterpolate (double x_start, double y_start, double z_start, double x_end, double y_end, double z_end, double newDistance, double totalDistanceToMove, double[] dstPoint) |
| Calculate the point between two points according to a given distance. More...
|
|
static boolean | isPowerOfTwo (int n) |
| Check a number if it is a power of two. More...
|
|
Util class for math operations.
static boolean com.beyondar.android.util.math.MathUtils.isPowerOfTwo |
( |
int |
n | ) |
|
|
static |
Check a number if it is a power of two.
- Parameters
-
- Returns
static void com.beyondar.android.util.math.MathUtils.linearInterpolate |
( |
float |
x_start, |
|
|
float |
y_start, |
|
|
float |
z_start, |
|
|
float |
x_end, |
|
|
float |
y_end, |
|
|
float |
z_end, |
|
|
float |
newDistance, |
|
|
float |
totalDistanceToMove, |
|
|
Point3 |
dstPoint |
|
) |
| |
|
static |
static void com.beyondar.android.util.math.MathUtils.linearInterpolate |
( |
double |
x_start, |
|
|
double |
y_start, |
|
|
double |
z_start, |
|
|
double |
x_end, |
|
|
double |
y_end, |
|
|
double |
z_end, |
|
|
double |
newDistance, |
|
|
double |
totalDistanceToMove, |
|
|
double[] |
dstPoint |
|
) |
| |
|
static |
Calculate the point between two points according to a given distance.
Source: http://tech-algorithm.com/articles/linear-interpolation/
- Parameters
-
x_start | |
y_start | |
z_start | |
x_end | |
y_end | |
z_end | |
newDistance | |
totalDistanceToMove | |
dstPoint | Array that will store the result of the calculus. [x, y, z] |
static float com.beyondar.android.util.math.MathUtils.metersToGlUnits |
( |
float |
meters | ) |
|
|
static |
Convert the meter units to the equivalent distance in the GL world.
- Parameters
-
- Returns
The documentation for this class was generated from the following file:
- src/com/beyondar/android/util/math/MathUtils.java