![]() |
http://www.sim.no http://www.coin3d.org |
The SbVec4us class is a 4 dimensional vector with unsigned short integer coordinates. More...
#include <Inventor/SbVec4us.h>
Public Member Functions | |
SbVec4us (void) | |
SbVec4us (const unsigned short v[4]) | |
SbVec4us (unsigned short x, unsigned short y, unsigned short z, unsigned short w) | |
SbVec4us (const SbVec4s &v) | |
SbVec4us (const SbVec4ub &v) | |
SbVec4us (const SbVec4ui32 &v) | |
SbVec4us & | setValue (const unsigned short v[4]) |
SbVec4us & | setValue (unsigned short x, unsigned short y, unsigned short z, unsigned short w) |
SbVec4us & | setValue (const SbVec4s &v) |
SbVec4us & | setValue (const SbVec4ub &v) |
SbVec4us & | setValue (const SbVec4ui32 &v) |
const unsigned short * | getValue (void) const |
void | getValue (unsigned short &x, unsigned short &y, unsigned short &z, unsigned short &w) const |
unsigned short & | operator[] (int i) |
const unsigned short & | operator[] (int i) const |
int32_t | dot (const SbVec4us &v) const |
void | negate (void) |
SbVec4us & | operator*= (int d) |
SbVec4us & | operator*= (double d) |
SbVec4us & | operator/= (int d) |
SbVec4us & | operator/= (double d) |
SbVec4us & | operator+= (const SbVec4us &v) |
SbVec4us & | operator-= (const SbVec4us &v) |
SbVec4us | operator- (void) const |
Protected Attributes | |
unsigned short | vec [4] |
The SbVec4us class is a 4 dimensional vector with unsigned short integer coordinates.
This vector class provides storage for a 3 dimensional homogeneoues vector (with the 4 components usually referred to as <x, y, z, w>) aswell as simple integer precision arithmetic operations.
SbVec4us::SbVec4us | ( | void | ) | [inline] |
The default constructor does nothing. The vector coordinates will be uninitialized until a call the setValue().
SbVec4us::SbVec4us | ( | const unsigned short | v[4] | ) | [inline] |
Constructs an SbVec4us instance with initial values from v.
SbVec4us::SbVec4us | ( | unsigned short | x, |
unsigned short | y, | ||
unsigned short | z, | ||
unsigned short | w | ||
) | [inline] |
Constructs an SbVec4us instance with the initial homogeneous vector set to <x,y,z,w>.
SbVec4us::SbVec4us | ( | const SbVec4s & | v | ) | [inline, explicit] |
Constructs an SbVec4us instance with initial values from the unsigned short integer precision vector v.
SbVec4us::SbVec4us | ( | const SbVec4ub & | v | ) | [inline, explicit] |
Constructs an SbVec4us instance with initial values from the 8-bit integer precision vector v.
SbVec4us::SbVec4us | ( | const SbVec4ui32 & | v | ) | [inline, explicit] |
Constructs an SbVec4us instance with initial values from the unsigned 32-bit integer precision vector v.
SbVec4us & SbVec4us::setValue | ( | const unsigned short | v[4] | ) | [inline] |
Set new coordinates for the vector from v. Returns reference to self.
SbVec4us & SbVec4us::setValue | ( | unsigned short | x, |
unsigned short | y, | ||
unsigned short | z, | ||
unsigned short | w | ||
) | [inline] |
Set new coordinates for the vector. Returns reference to self.
Sets this vector to the short integer precision vector v, converting the vector to a unsigned short integer precision vector.
Sets this vector to the unsigned 8-bit integer precision vector v, converting the vector to a unsigned short integer precision vector.
SbVec4us & SbVec4us::setValue | ( | const SbVec4ui32 & | v | ) |
Sets this vector to the unsigned 32-bit integer precision vector v, converting the vector to a unsigned short integer precision vector.
const unsigned short * SbVec4us::getValue | ( | void | ) | const [inline] |
Returns a pointer to an array of four unsigned short integers containing the x, y, z and w coordinates of the vector.
void SbVec4us::getValue | ( | unsigned short & | x, |
unsigned short & | y, | ||
unsigned short & | z, | ||
unsigned short & | w | ||
) | const [inline] |
Returns the x, y, z and w coordinates of the vector.
unsigned short & SbVec4us::operator[] | ( | int | i | ) | [inline] |
Index operator. Returns modifiable x, y, z or w coordinate of the vector.
const unsigned short & SbVec4us::operator[] | ( | int | i | ) | const [inline] |
Index operator. Returns non-modifiable x, y, z or w coordinate of the vector.
int32_t SbVec4us::dot | ( | const SbVec4us & | v | ) | const [inline] |
Calculates and returns the result of taking the dot product of this vector and v.
void SbVec4us::negate | ( | void | ) |
Negate the vector (i.e. point it in the opposite direction)
Referenced by operator-().
SbVec4us & SbVec4us::operator*= | ( | int | d | ) | [inline] |
Multiply components of vector with scalar value d. Returns reference to self.
SbVec4us & SbVec4us::operator*= | ( | double | d | ) |
Multiply components of vector with value d. Returns reference to self.
SbVec4us & SbVec4us::operator/= | ( | int | d | ) | [inline] |
Divides components of vector with scalar value d. Returns reference to self.
SbVec4us & SbVec4us::operator/= | ( | double | d | ) | [inline] |
Divides components of vector with scalar value d. Returns reference to self.
Adds this vector and vector u. Returns reference to self.
Subtracts v from this vector. Returns reference to self.
SbVec4us SbVec4us::operator- | ( | void | ) | const [inline] |
Copyright © 1998-2007 by Systems in Motion AS. All rights reserved.
Generated on Mon Feb 28 2011 10:12:02 for Coin by Doxygen. 1.7.3