LiquidFun
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
Public Member Functions | Public Attributes | List of all members
b2Vec3 Struct Reference

A 3D column vector with 3 elements. More...

#include <b2Math.h>

Public Member Functions

 b2Vec3 ()
 Default constructor does nothing (for performance).
 
 b2Vec3 (float32 x, float32 y, float32 z)
 Construct using coordinates.
 
void SetZero ()
 Set this vector to all zeros.
 
void Set (float32 x_, float32 y_, float32 z_)
 Set this vector to some specified coordinates.
 
b2Vec3 operator- () const
 Negate this vector.
 
void operator+= (const b2Vec3 &v)
 Add a vector to this vector.
 
void operator-= (const b2Vec3 &v)
 Subtract a vector from this vector.
 
void operator*= (float32 s)
 Multiply this vector by a scalar.
 
float32 Length () const
 Get the length of this vector (the norm).
 
float32 Normalize ()
 Convert this vector into a unit vector. Returns the length.
 

Public Attributes

float32 x
 
float32 y
 
float32 z
 

Detailed Description

A 3D column vector with 3 elements.


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