|
Infinity Engine v0.6.20
C++ API Documentation
|
Classes | |
| class | Ramp |
| Interpolated gradient for smoothly transitioning between values. More... | |
| struct | Rect |
| Axis-aligned rectangle defined by left, right, top, and bottom edges. More... | |
| struct | Stop |
| Represents a control point in a gradient or interpolation ramp. More... | |
| struct | t_Matrix3 |
| Template structure representing a 3x3 matrix. More... | |
| struct | t_Matrix4 |
| Template structure representing a 4x4 matrix. More... | |
| struct | t_Vector2 |
| Template structure representing a 2-component vector. More... | |
| struct | t_Vector3 |
| Template structure representing a 3-component vector. More... | |
| struct | t_Vector4 |
| Template structure representing a 4-component vector. More... | |
Typedefs | |
| using | Matrix3 = t_Matrix3< float > |
| Alias for t_Matrix3<float>, single-precision 3x3 matrix. | |
| using | Matrix3d = t_Matrix3< double > |
| Alias for t_Matrix3<double>, double-precision 3x3 matrix. | |
| using | Matrix4 = t_Matrix4< float > |
| Alias for t_Matrix4<float>, single-precision 4x4 matrix. | |
| using | Matrix4d = t_Matrix4< double > |
| Alias for t_Matrix4<double>, double-precision 4x4 matrix. | |
| using | ValueRamp = Ramp< float > |
| Alias for Ramp<float>, a scalar interpolation curve. | |
| using | Value2Ramp = Ramp< Vector2 > |
| Alias for Ramp<Vector2>, a 2D vector interpolation curve. | |
| using | Value3Ramp = Ramp< Vector3 > |
| Alias for Ramp<Vector3>, a 3D vector interpolation curve. | |
| using | Value4Ramp = Ramp< Vector4 > |
| Alias for Ramp<Vector4>, a 4D vector interpolation curve. | |
| using | ValueStop = Stop< float > |
| Alias for Stop<float>, a scalar gradient control point. | |
| using | Value2Stop = Stop< Vector2 > |
| Alias for Stop<Vector2>, a 2D vector gradient control point. | |
| using | Value3Stop = Stop< Vector3 > |
| Alias for Stop<Vector3>, a 3D vector gradient control point. | |
| using | Value4Stop = Stop< Vector4 > |
| Alias for Stop<Vector4>, a 4D vector gradient control point. | |
| using | Vector2 = t_Vector2< float > |
| Alias for t_Vector2<float>, the default 2D vector type. | |
| using | Vector2f = t_Vector2< float > |
| Alias for t_Vector2<float>, single-precision floating-point vector. | |
| using | Vector2d = t_Vector2< double > |
| Alias for t_Vector2<double>, double-precision floating-point vector. | |
| using | Vector2b = t_Vector2< int8_t > |
| Alias for t_Vector2<int8_t>, signed 8-bit integer vector. | |
| using | Vector2s = t_Vector2< int16_t > |
| Alias for t_Vector2<int16_t>, signed 16-bit integer vector. | |
| using | Vector2i = t_Vector2< int32_t > |
| Alias for t_Vector2<int32_t>, signed 32-bit integer vector. | |
| using | Vector2l = t_Vector2< int64_t > |
| Alias for t_Vector2<int64_t>, signed 64-bit integer vector. | |
| using | Vector2ub = t_Vector2< uint8_t > |
| Alias for t_Vector2<uint8_t>, unsigned 8-bit integer vector. | |
| using | Vector2us = t_Vector2< uint16_t > |
| Alias for t_Vector2<uint16_t>, unsigned 16-bit integer vector. | |
| using | Vector2ui = t_Vector2< uint32_t > |
| Alias for t_Vector2<uint32_t>, unsigned 32-bit integer vector. | |
| using | Vector2ul = t_Vector2< uint64_t > |
| Alias for t_Vector2<uint64_t>, unsigned 64-bit integer vector. | |
| using | Vector3 = t_Vector3< float > |
| Alias for t_Vector3<float>, the default 3D vector type. | |
| using | Vector3f = t_Vector3< float > |
| Alias for t_Vector3<float>, single-precision floating-point vector. | |
| using | Vector3d = t_Vector3< double > |
| Alias for t_Vector3<double>, double-precision floating-point vector. | |
| using | Vector3b = t_Vector3< int8_t > |
| Alias for t_Vector3<int8_t>, signed 8-bit integer vector. | |
| using | Vector3s = t_Vector3< int16_t > |
| Alias for t_Vector3<int16_t>, signed 16-bit integer vector. | |
| using | Vector3i = t_Vector3< int32_t > |
| Alias for t_Vector3<int32_t>, signed 32-bit integer vector. | |
| using | Vector3l = t_Vector3< int64_t > |
| Alias for t_Vector3<int64_t>, signed 64-bit integer vector. | |
| using | Vector3ub = t_Vector3< uint8_t > |
| Alias for t_Vector3<uint8_t>, unsigned 8-bit integer vector. | |
| using | Vector3us = t_Vector3< uint16_t > |
| Alias for t_Vector3<uint16_t>, unsigned 16-bit integer vector. | |
| using | Vector3ui = t_Vector3< uint32_t > |
| Alias for t_Vector3<uint32_t>, unsigned 32-bit integer vector. | |
| using | Vector3ul = t_Vector3< uint64_t > |
| Alias for t_Vector3<uint64_t>, unsigned 64-bit integer vector. | |
| using | Vector4 = t_Vector4< float > |
| Alias for t_Vector4<float>, the default 4D vector type. | |
| using | Quaternion = t_Vector4< float > |
| Alias for t_Vector4<float>, used for representing rotations. | |
| using | Vector4f = t_Vector4< float > |
| Alias for t_Vector4<float>, single-precision floating-point vector. | |
| using | Vector4d = t_Vector4< double > |
| Alias for t_Vector4<double>, double-precision floating-point vector. | |
| using | Vector4b = t_Vector4< int8_t > |
| Alias for t_Vector4<int8_t>, signed 8-bit integer vector. | |
| using | Vector4s = t_Vector4< int16_t > |
| Alias for t_Vector4<int16_t>, signed 16-bit integer vector. | |
| using | Vector4i = t_Vector4< int32_t > |
| Alias for t_Vector4<int32_t>, signed 32-bit integer vector. | |
| using | Vector4l = t_Vector4< int64_t > |
| Alias for t_Vector4<int64_t>, signed 64-bit integer vector. | |
| using | Vector4ub = t_Vector4< uint8_t > |
| Alias for t_Vector4<uint8_t>, unsigned 8-bit integer vector. | |
| using | Vector4us = t_Vector4< uint16_t > |
| Alias for t_Vector4<uint16_t>, unsigned 16-bit integer vector. | |
| using | Vector4ui = t_Vector4< uint32_t > |
| Alias for t_Vector4<uint32_t>, unsigned 32-bit integer vector. | |
| using | Vector4ul = t_Vector4< uint64_t > |
| Alias for t_Vector4<uint64_t>, unsigned 64-bit integer vector. | |
Functions | |
| constexpr float | radians (float degrees) |
| Converts degrees to radians (float). | |
| constexpr double | radians (double degrees) |
| Converts degrees to radians (double). | |
| constexpr float | degrees (float radians) |
| Converts radians to degrees (float). | |
| constexpr double | degrees (double radians) |
| Converts radians to degrees (double). | |
| float | normalizeAngle (float angle) |
| Normalizes an angle in radians to the range [-PI, PI]. | |
| double | normalizeAngle (double angle) |
| Normalizes an angle in radians to the range [-PI, PI] (double precision). | |
| float | normalizeAngleDegrees (float angle) |
| Normalizes an angle in degrees to the range [-180, 180]. | |
| double | normalizeAngleDegrees (double angle) |
| Normalizes an angle in degrees to the range [-180, 180] (double precision). | |
| Vector3 INFINITY_API_PUBLIC | lerp (const Vector3 &a, const Vector3 &b, float t) |
| Linear interpolation between two 3D vectors. | |
| Vector3 INFINITY_API_PUBLIC | mix (const Vector3 &a, const Vector3 &b, float t) |
| Linear interpolation between two 3D vectors (alias for lerp). | |
| Vector3 INFINITY_API_PUBLIC | quatToEuler (Quaternion quat) |
| Converts a quaternion to Euler angles. | |
| Quaternion INFINITY_API_PUBLIC | eulerToQuat (Vector3 euler) |
| Converts Euler angles to a quaternion. | |
| float INFINITY_API_PUBLIC | smoothstep (float s1, float s2, float val) |
| Smooth Hermite interpolation between two values. | |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &out, const t_Matrix3< T > &m) |
| Stream insertion operator for single-line text output. | |
| template<typename T > | |
| std::istream & | operator>> (std::istream &in, t_Matrix3< T > &m) |
| Stream extraction operator for single-line text input. | |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &out, const t_Matrix4< T > &m) |
| Stream insertion operator for single-line text output. | |
| template<typename T > | |
| std::istream & | operator>> (std::istream &in, t_Matrix4< T > &m) |
| Stream extraction operator for single-line text input. | |
| constexpr bool | operator== (const Rect &lhs, const Rect &rhs) |
| Equality comparison operator. | |
| constexpr bool | operator!= (const Rect &lhs, const Rect &rhs) |
| Inequality comparison operator. | |
| constexpr Rect | operator- (const Rect &lhs, const Rect &rhs) |
| Rectangle subtraction operator. | |
| constexpr Rect | operator- (const Rect &v) |
| Unary negation operator. | |
| constexpr Rect | operator+ (const Rect &lhs, const Rect &rhs) |
| Rectangle addition operator. | |
| std::ostream & | operator<< (std::ostream &out, const Rect &r) |
| Stream insertion operator for single-line text output. | |
| std::istream & | operator>> (std::istream &in, Rect &r) |
| Stream extraction operator for single-line text input. | |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &out, const Stop< T > &s) |
| Stream insertion operator for single-line text output. | |
| template<typename T > | |
| std::istream & | operator>> (std::istream &in, Stop< T > &s) |
| Stream extraction operator for single-line text input. | |
| template<typename T > | |
| constexpr bool | operator== (const t_Vector2< T > &lhs, const t_Vector2< T > &rhs) |
| Equality comparison operator. | |
| template<typename T > | |
| constexpr bool | operator!= (const t_Vector2< T > &lhs, const t_Vector2< T > &rhs) |
| Inequality comparison operator. | |
| template<typename T > | |
| constexpr bool | operator< (const t_Vector2< T > &lhs, const t_Vector2< T > &rhs) |
| Less-than comparison operator for ordering. | |
| template<typename T > | |
| constexpr t_Vector2< T > | operator- (const t_Vector2< T > &lhs, const t_Vector2< T > &rhs) |
| Component-wise vector subtraction. | |
| template<typename T > | |
| constexpr t_Vector2< T > | operator- (const t_Vector2< T > &v) |
| Unary negation operator. | |
| template<typename T > | |
| constexpr t_Vector2< T > | operator+ (const t_Vector2< T > &lhs, const t_Vector2< T > &rhs) |
| Component-wise vector addition. | |
| template<typename T > | |
| constexpr t_Vector2< T > | operator* (const t_Vector2< T > &lhs, T rhs) |
| Scalar multiplication. | |
| template<typename T > | |
| constexpr t_Vector2< T > | operator* (const t_Vector2< T > &lhs, const t_Vector2< T > &rhs) |
| Component-wise vector multiplication. | |
| template<typename T > | |
| constexpr t_Vector2< T > | operator/ (const t_Vector2< T > &lhs, T rhs) |
| Scalar division. | |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &out, const t_Vector2< T > &v) |
| Stream insertion operator for single-line text output. | |
| template<typename T > | |
| std::istream & | operator>> (std::istream &in, t_Vector2< T > &v) |
| Stream extraction operator for single-line text input. | |
| template<> | |
| std::istream & | operator>> (std::istream &in, t_Vector2< uint8_t > &v) |
| Stream extraction specialization for uint8_t vectors. | |
| template<typename T > | |
| constexpr bool | operator== (const t_Vector3< T > &lhs, const t_Vector3< T > &rhs) |
| Equality comparison operator. | |
| template<typename T > | |
| constexpr bool | operator!= (const t_Vector3< T > &lhs, const t_Vector3< T > &rhs) |
| Inequality comparison operator. | |
| template<typename T > | |
| constexpr bool | operator< (const t_Vector3< T > &lhs, const t_Vector3< T > &rhs) |
| Less-than comparison operator for ordering. | |
| template<typename T > | |
| constexpr t_Vector3< T > | operator- (const t_Vector3< T > &lhs, const t_Vector3< T > &rhs) |
| Component-wise vector subtraction. | |
| template<typename T > | |
| constexpr t_Vector3< T > | operator- (const t_Vector3< T > &v) |
| Unary negation operator. | |
| template<typename T > | |
| constexpr t_Vector3< T > | operator+ (const t_Vector3< T > &lhs, const t_Vector3< T > &rhs) |
| Component-wise vector addition. | |
| template<typename T > | |
| constexpr t_Vector3< T > | operator* (const t_Vector3< T > &lhs, T rhs) |
| Scalar multiplication. | |
| template<typename T > | |
| constexpr t_Vector3< T > | operator* (const t_Vector3< T > &lhs, const t_Vector3< T > &rhs) |
| Component-wise vector multiplication. | |
| template<typename T > | |
| constexpr t_Vector3< T > | operator/ (const t_Vector3< T > &lhs, T rhs) |
| Scalar division. | |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &out, const t_Vector3< T > &v) |
| Stream insertion operator for single-line text output. | |
| template<typename T > | |
| std::istream & | operator>> (std::istream &in, t_Vector3< T > &v) |
| Stream extraction operator for single-line text input. | |
| template<> | |
| std::istream & | operator>> (std::istream &in, t_Vector3< uint8_t > &v) |
| Stream extraction specialization for uint8_t vectors. | |
| template<typename T > | |
| constexpr bool | operator== (const t_Vector4< T > &lhs, const t_Vector4< T > &rhs) |
| Equality comparison operator. | |
| template<typename T > | |
| constexpr bool | operator!= (const t_Vector4< T > &lhs, const t_Vector4< T > &rhs) |
| Inequality comparison operator. | |
| template<typename T > | |
| constexpr bool | operator< (const t_Vector4< T > &lhs, const t_Vector4< T > &rhs) |
| Less-than comparison operator for ordering. | |
| template<typename T > | |
| constexpr t_Vector4< T > | operator- (const t_Vector4< T > &lhs, const t_Vector4< T > &rhs) |
| Component-wise vector subtraction. | |
| template<typename T > | |
| constexpr t_Vector4< T > | operator- (const t_Vector4< T > &v) |
| Unary negation operator. | |
| template<typename T > | |
| constexpr t_Vector4< T > | operator+ (const t_Vector4< T > &lhs, const t_Vector4< T > &rhs) |
| Component-wise vector addition. | |
| template<typename T > | |
| constexpr t_Vector4< T > | operator* (const t_Vector4< T > &lhs, T rhs) |
| Scalar multiplication. | |
| template<typename T > | |
| constexpr t_Vector4< T > | operator* (const t_Vector4< T > &lhs, const t_Vector4< T > &rhs) |
| Component-wise vector multiplication. | |
| template<typename T > | |
| constexpr t_Vector4< T > | operator/ (const t_Vector4< T > &lhs, T rhs) |
| Scalar division. | |
| template<typename T > | |
| std::ostream & | operator<< (std::ostream &out, const t_Vector4< T > &v) |
| Stream insertion operator for single-line text output. | |
| template<typename T > | |
| std::istream & | operator>> (std::istream &in, t_Vector4< T > &v) |
| Stream extraction operator for single-line text input. | |
| template<> | |
| std::istream & | operator>> (std::istream &in, t_Vector4< uint8_t > &v) |
| Stream extraction specialization for uint8_t vectors. | |
Variables | |
| constexpr float | PI = 3.14159265358979323846f |
| Mathematical constants. | |
| constexpr float | TWO_PI = 6.28318530717958647692f |
| constexpr float | HALF_PI = 1.57079632679489661923f |
| constexpr float | INV_PI = 0.31830988618379067154f |
| constexpr double | PI_D = 3.14159265358979323846 |
| constexpr double | TWO_PI_D = 6.28318530717958647692 |
| constexpr double | HALF_PI_D = 1.57079632679489661923 |
| constexpr double | INV_PI_D = 0.31830988618379067154 |
Alias for t_Matrix3<float>, single-precision 3x3 matrix.
Alias for t_Matrix3<double>, double-precision 3x3 matrix.
Alias for t_Matrix4<float>, single-precision 4x4 matrix.
The standard matrix type for 3D transformations in procedural generation and rendering pipelines.
Alias for t_Matrix4<double>, double-precision 4x4 matrix.
Used when higher precision is required for transformations, such as astronomical calculations or long transformation chains where error accumulation is a concern.
Alias for t_Vector4<float>, used for representing rotations.
Quaternions provide a compact, efficient representation of 3D rotations that avoids gimbal lock. The components (x, y, z, w) represent the rotation axis scaled by sin(θ/2) and w is cos(θ/2), where θ is the rotation angle. A normalized quaternion (length = 1) represents a valid rotation.
Alias for Ramp<Vector2>, a 2D vector interpolation curve.
Used for 2D transitions such as:
Alias for Stop<Vector2>, a 2D vector gradient control point.
Used for 2D interpolation curves such as:
Alias for Ramp<Vector3>, a 3D vector interpolation curve.
Used for 3D transitions such as:
Alias for Stop<Vector3>, a 3D vector gradient control point.
Used for 3D interpolation curves such as:
Alias for Ramp<Vector4>, a 4D vector interpolation curve.
Used for 4D transitions such as:
Alias for Stop<Vector4>, a 4D vector gradient control point.
Used for 4D interpolation curves such as:
Alias for Ramp<float>, a scalar interpolation curve.
Used for single-value transitions such as:
Alias for Stop<float>, a scalar gradient control point.
Used for single-value interpolation curves such as:
Alias for t_Vector2<float>, the default 2D vector type.
Alias for t_Vector2<int8_t>, signed 8-bit integer vector.
Alias for t_Vector2<double>, double-precision floating-point vector.
Alias for t_Vector2<float>, single-precision floating-point vector.
Alias for t_Vector2<int32_t>, signed 32-bit integer vector.
Alias for t_Vector2<int64_t>, signed 64-bit integer vector.
Alias for t_Vector2<int16_t>, signed 16-bit integer vector.
Alias for t_Vector2<uint8_t>, unsigned 8-bit integer vector.
Alias for t_Vector2<uint32_t>, unsigned 32-bit integer vector.
Alias for t_Vector2<uint64_t>, unsigned 64-bit integer vector.
Alias for t_Vector2<uint16_t>, unsigned 16-bit integer vector.
Alias for t_Vector3<float>, the default 3D vector type.
Alias for t_Vector3<int8_t>, signed 8-bit integer vector.
Alias for t_Vector3<double>, double-precision floating-point vector.
Alias for t_Vector3<float>, single-precision floating-point vector.
Alias for t_Vector3<int32_t>, signed 32-bit integer vector.
Alias for t_Vector3<int64_t>, signed 64-bit integer vector.
Alias for t_Vector3<int16_t>, signed 16-bit integer vector.
Alias for t_Vector3<uint8_t>, unsigned 8-bit integer vector.
Alias for t_Vector3<uint32_t>, unsigned 32-bit integer vector.
Alias for t_Vector3<uint64_t>, unsigned 64-bit integer vector.
Alias for t_Vector3<uint16_t>, unsigned 16-bit integer vector.
Alias for t_Vector4<float>, the default 4D vector type.
Alias for t_Vector4<int8_t>, signed 8-bit integer vector.
Alias for t_Vector4<double>, double-precision floating-point vector.
Alias for t_Vector4<float>, single-precision floating-point vector.
Alias for t_Vector4<int32_t>, signed 32-bit integer vector.
Alias for t_Vector4<int64_t>, signed 64-bit integer vector.
Alias for t_Vector4<int16_t>, signed 16-bit integer vector.
Alias for t_Vector4<uint8_t>, unsigned 8-bit integer vector.
Alias for t_Vector4<uint32_t>, unsigned 32-bit integer vector.
Alias for t_Vector4<uint64_t>, unsigned 64-bit integer vector.
Alias for t_Vector4<uint16_t>, unsigned 16-bit integer vector.
|
inlineconstexpr |
Converts radians to degrees (double).
| radians | Angle in radians. |
|
inlineconstexpr |
Converts radians to degrees (float).
| radians | Angle in radians. |
| Quaternion INFINITY_API_PUBLIC Infinity::Types::Math::eulerToQuat | ( | Vector3 | euler | ) |
Converts Euler angles to a quaternion.
Creates a quaternion representing the rotation specified by Euler angles. The input vector contains rotations in radians around the X, Y, and Z axes.
| euler | Vector3 containing Euler angles in radians (x=pitch, y=yaw, z=roll). |
| Vector3 INFINITY_API_PUBLIC Infinity::Types::Math::lerp | ( | const Vector3 & | a, |
| const Vector3 & | b, | ||
| float | t | ||
| ) |
Linear interpolation between two 3D vectors.
Computes a + (b - a) * t, providing smooth linear blending between two vectors. When t = 0, returns a; when t = 1, returns b.
Common uses in procedural generation:
| a | Start vector (returned when t = 0). |
| b | End vector (returned when t = 1). |
| t | Interpolation parameter (typically 0-1, but any value is valid). |
|
inline |
Normalizes an angle in radians to the range [-PI, PI] (double precision).
| angle | Angle in radians. |
|
inline |
Normalizes an angle in radians to the range [-PI, PI].
| angle | Angle in radians. |
|
inline |
Normalizes an angle in degrees to the range [-180, 180] (double precision).
| angle | Angle in degrees. |
|
inline |
Normalizes an angle in degrees to the range [-180, 180].
| angle | Angle in degrees. |
Inequality comparison operator.
| lhs | Left rectangle. |
| rhs | Right rectangle. |
|
constexpr |
Inequality comparison operator.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Inequality comparison operator.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Inequality comparison operator.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Component-wise vector multiplication.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Scalar multiplication.
| T | Component type. |
| lhs | Vector. |
| rhs | Scalar. |
|
constexpr |
Component-wise vector multiplication.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Scalar multiplication.
| T | Component type. |
| lhs | Vector. |
| rhs | Scalar. |
|
constexpr |
Component-wise vector multiplication.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Scalar multiplication.
| T | Component type. |
| lhs | Vector. |
| rhs | Scalar. |
Rectangle addition operator.
Adds edges element-wise.
| lhs | Left rectangle. |
| rhs | Right rectangle. |
|
constexpr |
Component-wise vector addition.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Component-wise vector addition.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Component-wise vector addition.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
Rectangle subtraction operator.
Subtracts edges element-wise.
| lhs | Left rectangle. |
| rhs | Right rectangle. |
Unary negation operator.
Returns a rectangle with all edges negated.
| v | Rectangle to negate. |
|
constexpr |
Component-wise vector subtraction.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Unary negation operator.
| T | Component type. |
| v | Vector to negate. |
|
constexpr |
Component-wise vector subtraction.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Unary negation operator.
| T | Component type. |
| v | Vector to negate. |
|
constexpr |
Component-wise vector subtraction.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Unary negation operator.
| T | Component type. |
| v | Vector to negate. |
|
constexpr |
Scalar division.
For floating-point types, multiplies by reciprocal for better performance.
| T | Component type. |
| lhs | Vector. |
| rhs | Scalar divisor. |
|
constexpr |
Scalar division.
For floating-point types, multiplies by reciprocal for better performance.
| T | Component type. |
| lhs | Vector. |
| rhs | Scalar divisor. |
|
constexpr |
Scalar division.
For floating-point types, multiplies by reciprocal for better performance.
| T | Component type. |
| lhs | Vector. |
| rhs | Scalar divisor. |
|
constexpr |
Less-than comparison operator for ordering.
Performs lexicographic comparison (compares x first, then y if x is equal). Useful for using vectors as keys in ordered containers like std::map.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Less-than comparison operator for ordering.
Performs lexicographic comparison (compares x first, then y, then z if previous are equal). Useful for using vectors as keys in ordered containers like std::map.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Less-than comparison operator for ordering.
Performs lexicographic comparison (compares x, then y, then z, then w if previous are equal). Useful for using vectors as keys in ordered containers like std::map.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
inline |
Stream insertion operator for single-line text output.
Outputs rectangle in format "l r t b" (space-separated edges).
| out | Output stream. |
| r | Rectangle to output. |
|
inline |
Stream insertion operator for single-line text output.
Outputs stop in format "position value" where value uses its own stream insertion operator.
| T | The value type stored in the stop. |
| out | Output stream. |
| s | The stop to output. |
|
inline |
Stream insertion operator for single-line text output.
Outputs matrix as three space-separated column vectors.
| T | Element type. |
| out | Output stream. |
| m | Matrix to output. |
|
inline |
Stream insertion operator for single-line text output.
Outputs matrix as four space-separated column vectors.
| T | Element type. |
| out | Output stream. |
| m | Matrix to output. |
|
inline |
Stream insertion operator for single-line text output.
Outputs vector in format "x y" (space-separated components).
| T | Component type. |
| out | Output stream. |
| v | Vector to output. |
|
inline |
Stream insertion operator for single-line text output.
Outputs vector in format "x y z" (space-separated components).
| T | Component type. |
| out | Output stream. |
| v | Vector to output. |
|
inline |
Stream insertion operator for single-line text output.
Outputs vector in format "x y z w" (space-separated components).
| T | Component type. |
| out | Output stream. |
| v | Vector to output. |
Equality comparison operator.
| lhs | Left rectangle. |
| rhs | Right rectangle. |
|
constexpr |
Equality comparison operator.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Equality comparison operator.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
constexpr |
Equality comparison operator.
| T | Component type. |
| lhs | Left vector. |
| rhs | Right vector. |
|
inline |
Stream extraction operator for single-line text input.
Reads rectangle in format "l r t b" (space-separated edges).
| in | Input stream. |
| r | Rectangle to read into. |
|
inline |
Stream extraction operator for single-line text input.
Reads stop in format "position value" where value uses its own stream extraction operator.
| T | The value type stored in the stop. |
| in | Input stream. |
| s | The stop to read into. |
|
inline |
Stream extraction operator for single-line text input.
Reads matrix as three space-separated column vectors.
| T | Element type. |
| in | Input stream. |
| m | Matrix to read into. |
|
inline |
Stream extraction operator for single-line text input.
Reads matrix as four space-separated column vectors.
| T | Element type. |
| in | Input stream. |
| m | Matrix to read into. |
|
inline |
Stream extraction operator for single-line text input.
Reads vector in format "x y" (space-separated components).
| T | Component type. |
| in | Input stream. |
| v | Vector to read into. |
|
inline |
Stream extraction specialization for uint8_t vectors.
Reads components as integers first to avoid stream treating them as characters, then converts to uint8_t.
| in | Input stream. |
| v | Vector to read into. |
|
inline |
Stream extraction operator for single-line text input.
Reads vector in format "x y z" (space-separated components).
| T | Component type. |
| in | Input stream. |
| v | Vector to read into. |
|
inline |
Stream extraction specialization for uint8_t vectors.
Reads components as integers first to avoid stream treating them as characters, then converts to uint8_t.
| in | Input stream. |
| v | Vector to read into. |
|
inline |
Stream extraction operator for single-line text input.
Reads vector in format "x y z w" (space-separated components).
| T | Component type. |
| in | Input stream. |
| v | Vector to read into. |
|
inline |
Stream extraction specialization for uint8_t vectors.
Reads components as integers first to avoid stream treating them as characters, then converts to uint8_t. This is particularly useful when reading RGBA color values in the range 0-255.
| in | Input stream. |
| v | Vector to read into. |
| Vector3 INFINITY_API_PUBLIC Infinity::Types::Math::quatToEuler | ( | Quaternion | quat | ) |
Converts a quaternion to Euler angles.
Extracts the rotation represented by a quaternion and converts it to Euler angles (pitch, yaw, roll). The returned vector contains rotations in radians around the X, Y, and Z axes respectively.
| quat | Quaternion to convert (should be normalized). |
|
inlineconstexpr |
Converts degrees to radians (double).
| degrees | Angle in degrees. |
|
inlineconstexpr |
Converts degrees to radians (float).
| degrees | Angle in degrees. |
| float INFINITY_API_PUBLIC Infinity::Types::Math::smoothstep | ( | float | s1, |
| float | s2, | ||
| float | val | ||
| ) |
Smooth Hermite interpolation between two values.
Provides smooth easing between s1 and s2 based on val, using the Hermite polynomial (3t² - 2t³). This creates smooth transitions with zero velocity at the endpoints, useful for creating natural-looking curves and gradients.
When val ≤ s1, returns 0.0. When val ≥ s2, returns 1.0. Between s1 and s2, returns a smoothly interpolated value.
Common uses:
| s1 | Start threshold (returns 0 when val ≤ s1). |
| s2 | End threshold (returns 1 when val ≥ s2). |
| val | Input value to remap. |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
|
constexpr |
Mathematical constants.
|
constexpr |
|
constexpr |
|
constexpr |