|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectwiiremotej.IRLight
public class IRLight
A light dot seen by the IR Sensor. IRLights are immutable. In Basic mode, only the light's position is reported. In Extended mode, a rough estimate of the light's size is also reported. In Full mode, the light's bounding box and intensity (more accurate than size) are also reported.
Constructor Summary | |
---|---|
IRLight(int x,
int y)
Creates a new IRLight (basic mode) with the given position. |
|
IRLight(int x,
int y,
int size)
Creates a new IRLight (extended mode) with the given position and size. |
|
IRLight(int x,
int y,
int size,
int xMin,
int yMin,
int xMax,
int yMax,
int intensity)
Creates a new IRLight (full mode) with the given position, size, bounds, and intensity. |
Method Summary | |
---|---|
boolean |
equals(java.lang.Object other)
Returns true if this IRLight is equivalent to the given IRLight; otherwise false . |
double |
getIntensity()
Returns the intensity of the light dot from 0 to 1 (percent). |
double |
getSize()
Returns the size of the light dot from 0 to 1 (percent). |
double |
getX()
Returns the X coordinate of the light dot from 0 to 1 (percent). |
double |
getXMax()
Returns the maximum X coordinate of the light dot's bounding box from 0 to 1 (percent). |
double |
getXMin()
Returns the minimum X coordinate of the light dot's bounding box from 0 to 1 (percent). |
double |
getY()
Returns the Y coordinate of the light dot from 0 to 1 (percent). |
double |
getYMax()
Returns the maximum Y coordinate of the light dot's bounding box from 0 to 1 (percent). |
double |
getYMin()
Returns the minimum Y coordinate of the light dot's bounding box from 0 to 1 (percent). |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public IRLight(int x, int y)
x
- X position of the light (0-1023).y
- Y position of the light (0-767).public IRLight(int x, int y, int size)
x
- X position of the light (0-1023).y
- Y position of the light (0-767).size
- size of the light (0-15).public IRLight(int x, int y, int size, int xMin, int yMin, int xMax, int yMax, int intensity)
x
- X position of the light (0-1023).y
- Y position of the light (0-767).size
- size of the light (0-15).xMin
- the minimum X position of the light's bounding box (0-1023).yMin
- the minimum Y position of the light's bounding box (0-767).xMax
- the maximum X position of the light's bounding box (0-1023).yMax
- the maximum Y position of the light's bounding box (0-767).intensity
- the intensity of the light (0-255).Method Detail |
---|
public double getX()
public double getY()
public double getSize()
public double getXMin()
public double getYMin()
public double getXMax()
public double getYMax()
public double getIntensity()
public boolean equals(java.lang.Object other)
true
if this IRLight is equivalent to the given IRLight; otherwise false
. Coordinates, size, bounding box, and intensity
must all match.
equals
in class java.lang.Object
other
- the other IRLight to compare to.
true
if this IRLight is equivalent to the given IRLight; otherwise false
.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |