Kanzi 3.9.10
vector2.hpp File Reference

Classes

class  kanzi::Vector2
 Vector with 2 floating point components: (x, y). More...
 

Namespaces

namespace  kanzi
 

Functions

Vector2 kanzi::componentAbs (Vector2 v)
 Calculates component-wise absolute value for all elements and returns resulting vector.
 
Vector2 kanzi::componentAdd (Vector2 v, float scalar)
 Adds a value to all elements of a vector and returns the result.
 
bool kanzi::componentAllGreaterThan (Vector2 a, Vector2 b)
 Returns whether each component of the first vector is greater than the corresponding component of the second vector.
 
bool kanzi::componentAllGreaterThanOrEqual (Vector2 a, Vector2 b)
 Returns whether each component of the first vector is greater than or equal to the corresponding component of the second vector.
 
bool kanzi::componentAllLessThan (Vector2 a, Vector2 b)
 Returns whether each component of the first vector is less than the corresponding component of the second vector.
 
bool kanzi::componentAllLessThanOrEqual (Vector2 a, Vector2 b)
 Returns whether each component of the first vector is less than or equal to the corresponding component of the second vector.
 
Vector2 kanzi::componentCeil (Vector2 v)
 Calculates component-wise ceil value for all elements and returns resulting vector.
 
Vector2 kanzi::componentFloor (Vector2 v)
 Calculates component-wise floor value for all elements and returns resulting vector.
 
Vector2 kanzi::componentRound (Vector2 v)
 Calculates component-wise rounded value for all elements and returns resulting vector.
 
Vector2 kanzi::componentSqrt (Vector2 v)
 Calculates component-wise square root all elements and returns resulting vector.
 
Vector2 kanzi::componentSubtract (Vector2 v, float scalar)
 Subtracts a value from all elements of a vector and returns the result.
 
Vector2 kanzi::componentWiseDivide (Vector2 v1, Vector2 v2)
 Divides all vector elements component-wise and returns the resulting vector.
 
Vector2 kanzi::componentWiseMax (Vector2 v1, Vector2 v2)
 Calculates the component-wise maximum for all vector elements and returns the resulting vector.
 
Vector2 kanzi::componentWiseMin (Vector2 v1, Vector2 v2)
 Calculates the component-wise minimum for all vector elements and returns the resulting vector.
 
Vector2 kanzi::componentWiseMultiply (Vector2 v1, Vector2 v2)
 Multiplies all vector elements component-wise and returns the resulting vector.
 
Vector2 kanzi::componentWiseRemainder (Vector2 v1, Vector2 v2)
 Calculates component-wise the remainder for all vector elements and returns the resulting vector.
 
float kanzi::dotProduct (Vector2 v1, Vector2 v2)
 Calculates the dot product of two vectors.
 
bool kanzi::isfinite (Vector2 vec)
 Overloading of kanzi::isfinite for kanzi::Vector2.
 
bool kanzi::operator!= (Vector2 v1, Vector2 v2)
 Compares two vectors for inequality.
 
Vector2 kanzi::operator* (float scalar, Vector2 v)
 Multiplies all vector elements with a scalar and returns the resulting vector.
 
Vector2 kanzi::operator* (Vector2 v, float scalar)
 Multiplies all vector elements with a scalar and returns the resulting vector.
 
Vector2 kanzi::operator+ (float v1, Vector2 v2)
 Adds a scalar and a vector and returns the sum.
 
Vector2 kanzi::operator+ (Vector2 v)
 Unary plus, doesn't do anything and returns the resulting vector.
 
Vector2 kanzi::operator+ (Vector2 v1, float v2)
 Adds a vector and a scalar and returns the sum.
 
Vector2 kanzi::operator+ (Vector2 v1, Vector2 v2)
 Adds two vectors and returns the sum.
 
Vector2 kanzi::operator- (Vector2 v)
 Negates all vector elements and returns the resulting vector.
 
Vector2 kanzi::operator- (Vector2 v1, Vector2 v2)
 Subtracts two vectors and returns the difference.
 
Vector2 kanzi::operator/ (Vector2 v, float scalar)
 Divides all vector elements with a scalar and returns the resulting vector.
 
bool kanzi::operator== (Vector2 v1, Vector2 v2)
 Compares two vectors for equality.
 
float kanzi::pseudoCrossProduct (const Vector2 &left, const Vector2 &right)
 Calculates pseudo-cross product of two 2D vectors.