|
| union { |
| struct { |
| float x |
| |
| float y |
| |
| } | |
| |
| float data [2] |
| |
| }; | |
| |
| Legion::Vector2f::Vector2f |
( |
| ) |
|
| Legion::Vector2f::Vector2f |
( |
const float |
x, |
|
|
const float |
y |
|
) |
| |
| Legion::Vector2f::Vector2f |
( |
const float * |
tuple | ) |
|
| Legion::Vector2f::Vector2f |
( |
const Vector2f & |
other | ) |
|
| Legion::Vector2f::Vector2f |
( |
const Vector2d & |
other | ) |
|
| float Legion::Vector2f::angle |
( |
| ) |
const |
|
inline |
Calculates the angle of this vector in grad in the counter trigonometric sense.
- Returns
- Returns a value between 0 and 360.
| float Legion::Vector2f::angleBetween |
( |
const Vector2f & |
b | ) |
const |
|
inline |
Calculates the angle between this vector and another one in grad.
- Returns
- Returns a value between 0 and 90.
| float Legion::Vector2f::angleTrig |
( |
| ) |
const |
|
inline |
Calculates the angle of this vector in grad in the trigonometric sense.
- Returns
- Returns a value between 0 and 360.
| float Legion::Vector2f::distanceFrom |
( |
const Vector2f & |
other | ) |
const |
|
inline |
| float Legion::Vector2f::distanceFromSquared |
( |
const Vector2f & |
other | ) |
const |
|
inline |
| float Legion::Vector2f::dot |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| float Legion::Vector2f::dotPerp |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
returns interpolated vector
- Parameters
-
| other,: | other vector to interpolate between |
| d,: | value between 0.0f and 1.0f. |
| void Legion::Vector2f::invert |
( |
| ) |
|
|
inline |
| bool Legion::Vector2f::isBetweenPoints |
( |
const Vector2f & |
begin, |
|
|
const Vector2f & |
end |
|
) |
| const |
|
inline |
Returns if this vector interpreted as a point is on a line between two other points.
It is assumed that the point is on the line.
- Parameters
-
| begin,: | Beginning vector to compare between. |
| end,: | Ending vector to compare between. |
- Returns
- True if this vector is between begin and end. False if not.
| bool Legion::Vector2f::isZero |
( |
| ) |
|
|
inline |
| float Legion::Vector2f::length |
( |
| ) |
const |
|
inline |
| float Legion::Vector2f::lengthSquared |
( |
| ) |
const |
|
inline |
| float Legion::Vector2f::normalize |
( |
| ) |
|
|
inline |
| bool Legion::Vector2f::operator!= |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| Vector2f Legion::Vector2f::operator* |
( |
float |
scalar | ) |
const |
|
inline |
| Vector2f& Legion::Vector2f::operator*= |
( |
float |
scalar | ) |
|
|
inline |
| Vector2f Legion::Vector2f::operator- |
( |
| ) |
const |
|
inline |
| Vector2f Legion::Vector2f::operator/ |
( |
float |
scalar | ) |
const |
|
inline |
| Vector2f& Legion::Vector2f::operator/= |
( |
float |
scalar | ) |
|
|
inline |
| bool Legion::Vector2f::operator< |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| bool Legion::Vector2f::operator<= |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| bool Legion::Vector2f::operator== |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| bool Legion::Vector2f::operator> |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| bool Legion::Vector2f::operator>= |
( |
const Vector2f & |
vec | ) |
const |
|
inline |
| Vector2f Legion::Vector2f::perpendicular |
( |
| ) |
const |
|
inline |
| void Legion::Vector2f::rotateBy |
( |
float |
degrees, |
|
|
const Vector2f & |
center |
|
) |
| |
|
inline |
rotates the point around a center by an amount of degrees.
| void Legion::Vector2f::setLength |
( |
float |
newLength | ) |
|
|
inline |
| Vector2f Legion::Vector2f::unitPerp |
( |
| ) |
const |
|
inline |
| float Legion::Vector2f::data[2] |
| float Legion::Vector2f::x |
| float Legion::Vector2f::y |
The documentation for this class was generated from the following file: