PeriDyno 1.0.0
Loading...
Searching...
No Matches
vgm::Vec2 Class Reference

#include <vgMath.h>

Public Member Functions

 Vec2 ()=default
 
 Vec2 (const VEC2_T &)=default
 
 Vec2 (T s)
 
 Vec2 (T x, T y)
 
Vec2 operator- () const
 
Vec2operator+= (const Vec2 &v)
 
Vec2operator-= (const Vec2 &v)
 
Vec2operator*= (const Vec2 &v)
 
Vec2operator/= (const Vec2 &v)
 
Vec2operator*= (T s)
 
Vec2operator/= (T s)
 
Vec2 operator+ (const Vec2 &v) const
 
Vec2 operator- (const Vec2 &v) const
 
Vec2 operator* (const Vec2 &v) const
 
Vec2 operator/ (const Vec2 &v) const
 
Vec2 operator* (T s) const
 
Vec2 operator/ (T s) const
 
const Toperator[] (int i) const
 
Toperator[] (int i)
 
 operator const T * () const
 
 operator T* ()
 

Public Attributes

union { 
 
   struct { 
 
      T   x 
 
      T   y 
 
   }  
 
   struct { 
 
      T   u 
 
      T   v 
 
   }  
 
};  
 

Detailed Description

Definition at line 110 of file vgMath.h.

Constructor & Destructor Documentation

◆ Vec2() [1/4]

vgm::Vec2::Vec2 ( )
default
Here is the caller graph for this function:

◆ Vec2() [2/4]

vgm::Vec2::Vec2 ( const VEC2_T & )
default

◆ Vec2() [3/4]

vgm::Vec2::Vec2 ( T s)
inlineexplicit

Definition at line 119 of file vgMath.h.

◆ Vec2() [4/4]

vgm::Vec2::Vec2 ( T x,
T y )
inline

Definition at line 120 of file vgMath.h.

Member Function Documentation

◆ operator const T *()

vgm::Vec2::operator const T * ( ) const
inlineexplicit

Definition at line 141 of file vgMath.h.

◆ operator T*()

vgm::Vec2::operator T* ( )
inlineexplicit

Definition at line 142 of file vgMath.h.

◆ operator*() [1/2]

Vec2 vgm::Vec2::operator* ( const Vec2 & v) const
inline

Definition at line 133 of file vgMath.h.

Here is the call graph for this function:

◆ operator*() [2/2]

Vec2 vgm::Vec2::operator* ( T s) const
inline

Definition at line 135 of file vgMath.h.

Here is the call graph for this function:

◆ operator*=() [1/2]

Vec2 & vgm::Vec2::operator*= ( const Vec2 & v)
inline

Definition at line 126 of file vgMath.h.

Here is the call graph for this function:

◆ operator*=() [2/2]

Vec2 & vgm::Vec2::operator*= ( T s)
inline

Definition at line 128 of file vgMath.h.

Here is the call graph for this function:

◆ operator+()

Vec2 vgm::Vec2::operator+ ( const Vec2 & v) const
inline

Definition at line 131 of file vgMath.h.

Here is the call graph for this function:

◆ operator+=()

Vec2 & vgm::Vec2::operator+= ( const Vec2 & v)
inline

Definition at line 124 of file vgMath.h.

Here is the call graph for this function:

◆ operator-() [1/2]

Vec2 vgm::Vec2::operator- ( ) const
inline

Definition at line 122 of file vgMath.h.

Here is the call graph for this function:

◆ operator-() [2/2]

Vec2 vgm::Vec2::operator- ( const Vec2 & v) const
inline

Definition at line 132 of file vgMath.h.

Here is the call graph for this function:

◆ operator-=()

Vec2 & vgm::Vec2::operator-= ( const Vec2 & v)
inline

Definition at line 125 of file vgMath.h.

Here is the call graph for this function:

◆ operator/() [1/2]

Vec2 vgm::Vec2::operator/ ( const Vec2 & v) const
inline

Definition at line 134 of file vgMath.h.

Here is the call graph for this function:

◆ operator/() [2/2]

Vec2 vgm::Vec2::operator/ ( T s) const
inline

Definition at line 136 of file vgMath.h.

Here is the call graph for this function:

◆ operator/=() [1/2]

Vec2 & vgm::Vec2::operator/= ( const Vec2 & v)
inline

Definition at line 127 of file vgMath.h.

Here is the call graph for this function:

◆ operator/=() [2/2]

Vec2 & vgm::Vec2::operator/= ( T s)
inline

Definition at line 129 of file vgMath.h.

Here is the call graph for this function:

◆ operator[]() [1/2]

T & vgm::Vec2::operator[] ( int i)
inline

Definition at line 139 of file vgMath.h.

◆ operator[]() [2/2]

const T & vgm::Vec2::operator[] ( int i) const
inline

Definition at line 138 of file vgMath.h.

Member Data Documentation

◆ [union]

union { ... } vgm::Vec2

◆ u

T vgm::Vec2::u

Definition at line 114 of file vgMath.h.

◆ v

T vgm::Vec2::v

Definition at line 114 of file vgMath.h.

◆ x

T vgm::Vec2::x

Definition at line 113 of file vgMath.h.

◆ y

T vgm::Vec2::y

Definition at line 113 of file vgMath.h.


The documentation for this class was generated from the following file: