|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwiiremotej.PositionInfo
public class PositionInfo
Contains information about the WiiRemote's current position, including Y and Z position, pitch, and roll. It can also return either X position OR yaw, but not both. See isYawAllowed() for details. Here is a basic diagram explaining what each value means.
pitch (e.g., flip up so that the remote is vertical) ^ | |----| --> yaw (e.g., spin around so that the front is at the back) | | | | /\ | A | / \ > roll (e.g., flip over to expose the B button) z (from top to bottom) | | (not shown) | | | | | y (from front to back) | | | |----| --x-- (from left to right)
WRIREvent
,
WRAccelerationEvent
,
isYawAllowed()
Method Summary | |
---|---|
boolean |
isYawAllowed()
Returns true if the user can yaw the remote and false if the user can move it horizontally. |
double |
pitch()
Returns pitch. |
double |
roll()
Returns roll. |
double |
xPos()
Returns xPos. |
double |
yaw()
Returns yaw. |
double |
yPos()
Returns yPos. |
double |
zPos()
Returns zPos. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public double xPos()
isYawAllowed()
public double yPos()
public double zPos()
public double pitch()
public double yaw()
isYawAllowed()
public double roll()
public boolean isYawAllowed()
true
if the user can yaw the remote and false
if the user can move it horizontally. These conditions are mutually exclusive.
We are limited to five degrees of freedom, so we must assume that either yaw is 0 or x position is 0. If these assumptions are faulty (user error), the data is
meaningless. Obviously, it would be impossible to make these values EXACTLY 0 without considerable effort. So long as they are close, it's fine.
true
if the user can yaw the remote and false
if the user can move it horizontally. These conditions are mutually exclusive.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |