VR-Link JAVA API Documentation
 All Classes Namespaces Files Functions Variables Enumerator Pages
List of all members | Public Member Functions | Static Public Attributes | Private Attributes
com.mak.vrlj.math.Quaternion Class Reference

Quaternion. More...

+ Inheritance diagram for com.mak.vrlj.math.Quaternion:
+ Collaboration diagram for com.mak.vrlj.math.Quaternion:

Public Member Functions

 Quaternion ()
 No-arg constructor. More...
 
 Quaternion (ConstQuaternion other)
 Copy constructor. More...
 
 Quaternion (double px, double py, double pz, double pw)
 Construct from primitives. More...
 
void assignFrom (ConstQuaternion other)
 Assign this from another. More...
 
boolean equals (Object obj)
 
double getW ()
 Gets the w component. More...
 
double getX ()
 Gets the x component. More...
 
double getY ()
 Gets the y component. More...
 
double getZ ()
 Gets the z component. More...
 
int hashCode ()
 
void setW (double pw)
 Sets the w component. More...
 
void setX (double px)
 Sets the x component. More...
 
void setY (double py)
 Sets the y component. More...
 
void setZ (double pz)
 Sets the z component. More...
 
String toString ()
 

Static Public Attributes

static final Quaternion zero = new Quaternion(0, 0, 0, 0)
 A quaterion with all zero components. More...
 
static final Quaternion identity = new Quaternion(1, 0, 0, 0)
 A quaterion representing an identity. More...
 
static final Quaternion wAxis = new Quaternion(1, 0, 0, 0)
 A quaterion representing the W axis. More...
 
static final Quaternion xAxis = new Quaternion(0, 1, 0, 0)
 A quaterion representing the X axis. More...
 
static final Quaternion yAxis = new Quaternion(0, 0, 1, 0)
 A quaterion representing the Y axis. More...
 
static final Quaternion zAxis = new Quaternion(0, 0, 0, 1)
 A quaterion representing the Z axis. More...
 

Private Attributes

double x
 
double y
 
double z
 
double w
 

Detailed Description

Quaternion.

Constructor & Destructor Documentation

com.mak.vrlj.math.Quaternion.Quaternion ( )
inline

No-arg constructor.

Referenced by com.mak.vrlj.math.Quaternion.equals().

com.mak.vrlj.math.Quaternion.Quaternion ( ConstQuaternion  other)
inline
com.mak.vrlj.math.Quaternion.Quaternion ( double  px,
double  py,
double  pz,
double  pw 
)
inline

Construct from primitives.

Parameters
pxx component.
pyy component.
pzz component.
pww component.

References com.mak.vrlj.math.Quaternion.w, com.mak.vrlj.math.Quaternion.x, com.mak.vrlj.math.Quaternion.y, and com.mak.vrlj.math.Quaternion.z.

Member Function Documentation

void com.mak.vrlj.math.Quaternion.assignFrom ( ConstQuaternion  other)
inline

Assign this from another.

Parameters
othersource for assignment.

References com.mak.vrlj.math.Quaternion.w, com.mak.vrlj.math.Quaternion.x, com.mak.vrlj.math.Quaternion.y, and com.mak.vrlj.math.Quaternion.z.

boolean com.mak.vrlj.math.Quaternion.equals ( Object  obj)
inline
double com.mak.vrlj.math.Quaternion.getW ( )
inlinevirtual

Gets the w component.

Returns
the w

Implements com.mak.vrlj.math.ConstQuaternion.

References com.mak.vrlj.math.Quaternion.w.

double com.mak.vrlj.math.Quaternion.getX ( )
inlinevirtual

Gets the x component.

Returns
the x

Implements com.mak.vrlj.math.ConstQuaternion.

References com.mak.vrlj.math.Quaternion.x.

double com.mak.vrlj.math.Quaternion.getY ( )
inlinevirtual

Gets the y component.

Returns
the y

Implements com.mak.vrlj.math.ConstQuaternion.

References com.mak.vrlj.math.Quaternion.y.

double com.mak.vrlj.math.Quaternion.getZ ( )
inlinevirtual

Gets the z component.

Returns
the z

Implements com.mak.vrlj.math.ConstQuaternion.

References com.mak.vrlj.math.Quaternion.z.

int com.mak.vrlj.math.Quaternion.hashCode ( )
inline
void com.mak.vrlj.math.Quaternion.setW ( double  pw)
inline

Sets the w component.

Parameters
pwthe w component value.

References com.mak.vrlj.math.Quaternion.w.

void com.mak.vrlj.math.Quaternion.setX ( double  px)
inline

Sets the x component.

Parameters
pxthe x component value.

References com.mak.vrlj.math.Quaternion.x.

void com.mak.vrlj.math.Quaternion.setY ( double  py)
inline

Sets the y component.

Parameters
pythe y component value.

References com.mak.vrlj.math.Quaternion.y.

void com.mak.vrlj.math.Quaternion.setZ ( double  pz)
inline

Sets the z component.

Parameters
pzthe z component value.

References com.mak.vrlj.math.Quaternion.z.

String com.mak.vrlj.math.Quaternion.toString ( )
inline

Member Data Documentation

final Quaternion com.mak.vrlj.math.Quaternion.identity = new Quaternion(1, 0, 0, 0)
static

A quaterion representing an identity.

double com.mak.vrlj.math.Quaternion.w
private
final Quaternion com.mak.vrlj.math.Quaternion.wAxis = new Quaternion(1, 0, 0, 0)
static

A quaterion representing the W axis.

double com.mak.vrlj.math.Quaternion.x
private
final Quaternion com.mak.vrlj.math.Quaternion.xAxis = new Quaternion(0, 1, 0, 0)
static

A quaterion representing the X axis.

double com.mak.vrlj.math.Quaternion.y
private
final Quaternion com.mak.vrlj.math.Quaternion.yAxis = new Quaternion(0, 0, 1, 0)
static

A quaterion representing the Y axis.

double com.mak.vrlj.math.Quaternion.z
private
final Quaternion com.mak.vrlj.math.Quaternion.zAxis = new Quaternion(0, 0, 0, 1)
static

A quaterion representing the Z axis.

final Quaternion com.mak.vrlj.math.Quaternion.zero = new Quaternion(0, 0, 0, 0)
static

A quaterion with all zero components.


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

Document ID: Generated on Mon Sep 28 00:09:32 EDT 2026 from SVN revision 295353
Copyright © 1992-2025 MAK Technologies. All Rights Reserved (www.mak.com)