Adding stubs for TVector3 helper functions.
This commit is contained in:
parent
a4d794bac7
commit
38aad873ff
1 changed files with 35 additions and 0 deletions
|
@ -24,6 +24,8 @@
|
|||
TVector3( void );
|
||||
TVector3( BaseType X, BaseType Y, BaseType Z );
|
||||
|
||||
// compare Len, which isn't added yet
|
||||
//bool operator<( const TVector3& ) const;
|
||||
bool operator==( const TVector3& ) const;
|
||||
bool operator!=( const TVector3& ) const;
|
||||
|
||||
|
@ -44,6 +46,39 @@
|
|||
|
||||
// TODO: Add other helper functions
|
||||
|
||||
// Can only be used on non-zero vectors. Returns *this so you can chain method calls.
|
||||
TVector3& Normalize( void );
|
||||
TVector3& Clamp( BaseType maxLength );
|
||||
TVector3& Clamp( BaseType minLength, BaseType maxLength );
|
||||
TVector3& SetLen( BaseType length );
|
||||
|
||||
BaseType Len( void );
|
||||
BaseType LenSqr( void );
|
||||
|
||||
BaseType Dist( void );
|
||||
BaseType DistSqr( void );
|
||||
|
||||
BaseType Dot( const TVector3& v );
|
||||
|
||||
BaseType Angle( const TVector3& v );
|
||||
BaseType AngleNorm( const TVector3& v );
|
||||
|
||||
TVector3 Cross( const TVector3& v );
|
||||
TVector3 Perpendicular( void );
|
||||
TVector3 Project( const TVector3& v );
|
||||
TVector3 Reflect( const TVector3& v );
|
||||
TVector3 Rotate( BaseType angle, const TVector3& axis );
|
||||
|
||||
TVector3 Lerp( const TVector3& v, BaseType n );
|
||||
TVector3 Slerp( const TVector3& v, BaseType n );
|
||||
TVector3 Nlerp( const TVector3& v, BaseType n );
|
||||
|
||||
// might be confusing as method? At least with function you have parameters to
|
||||
// tell user what the vector representatio is.
|
||||
TVector3 ToPolar( void );
|
||||
TVector3 ToCartesian( void );
|
||||
TVector3 ToEuler( BaseType angle );
|
||||
|
||||
bool IsZero( void ) const;
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue