Graphics Reference
In-Depth Information
C
Vec3 C++ Class
It is also helpful to have a 3-element vector class. Here is one called Vec3 . These
are its methods:
Vec3( float = 0., float = 0., float = 0. );
Vec3( const Vec3& );
Vec3& operator=( const Vec3& );
Vec3& operator*=( float );
Vec3 operator+( const Vec3& );
Vec3& operator+=( const Vec3& );
Vec3 operator-( const Vec3& ); // binary -
Vec3 operator-( ); // unary -
Vec3& operator-=( const Vec3& );
Vec3 Cross( Vec3 );
float Dot( Vec3 );
void GetVec3( float * );
473
Search WWH ::




Custom Search