|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.openmali.vecmath2.TupleNi<Tuple2i>
org.openmali.vecmath2.Tuple2i
org.openmali.vecmath2.Point2i
public class Point2i
A 2 element point that is represented by signed integer x,y coordinates. Inspired by Kenji Hiranabe's Point2i implementation
| Field Summary | |
|---|---|
static Point2i |
ZERO
|
| Fields inherited from class org.openmali.vecmath2.TupleNi |
|---|
isDirty, N, roTrick, values |
| Constructor Summary | |
|---|---|
|
Point2i()
Constructs and initializes a Point3i to (0,0,0). |
protected |
Point2i(boolean readOnly)
Constructs and initializes a Point3i to (0,0,0). |
protected |
Point2i(boolean readOnly,
int[] values,
boolean[] isDirty,
boolean copy)
Constructs and initializes a Point3i from the specified array. |
protected |
Point2i(boolean readOnly,
int x,
int y)
Constructs and initializes a Point3i from the specified xyz coordinates. |
protected |
Point2i(boolean readOnly,
Tuple2i tuple)
Constructs and initializes a Point3i from the specified Point3i. |
|
Point2i(int[] values)
Constructs and initializes a Point3i from the specified array. |
|
Point2i(int x,
int y)
Constructs and initializes a Point3i from the specified xyz coordinates. |
|
Point2i(Tuple2i tuple)
Constructs and initializes a Point3i from the specified Point3i. |
| Method Summary | |
|---|---|
Point2i |
asReadOnly()
|
Point2i |
clone()
Creates and returns a copy of this object. |
static Point2i |
fromPool()
Allocates an Point2i instance from the pool. |
static Point2i |
fromPool(int x,
int y)
Allocates an Point2i instance from the pool. |
static Point2i |
fromPool(Tuple2i tuple)
Allocates an Point2i instance from the pool. |
Point2i |
getReadOnly()
|
static Point2i |
newReadOnly()
Constructs and initializes a Point3i to (0,0,0). |
static Point2i |
newReadOnly(int[] values)
Constructs and initializes a Point3i from the specified array. |
static Point2i |
newReadOnly(int x,
int y)
Constructs and initializes a Point3i from the specified xyz coordinates. |
static Point2i |
newReadOnly(Tuple2i tuple)
Constructs and initializes a Point3i from the specified Point3i. |
static void |
toPool(Point2i o)
Stores the given Point2i instance in the pool. |
| Methods inherited from class org.openmali.vecmath2.Tuple2i |
|---|
add, addX, addY, div, divX, divY, equals, equals, getX, getY, hashCode, mul, mulX, mulY, scale, set, setX, setY, sub, subX, subY, toPool, toString, x, x, y, y |
| Methods inherited from class org.openmali.vecmath2.TupleNi |
|---|
absolute, absolute, add, add, clamp, clamp, clampMax, clampMax, clampMin, clampMin, deserialize, get, get, get, getSerializationBufferSize, getSize, getValue, isDirty, isReadOnly, negate, negate, readExternal, scale, scale, scaleAdd, scaleAdd, serialize, set, set, set, setClean, setValue, setZero, sub, sub, writeExternal |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.io.Externalizable |
|---|
readExternal, writeExternal |
| Field Detail |
|---|
public static final Point2i ZERO
| Constructor Detail |
|---|
protected Point2i(boolean readOnly,
int x,
int y)
readOnly - x - the x coordinatey - the y coordinate
protected Point2i(boolean readOnly,
int[] values,
boolean[] isDirty,
boolean copy)
readOnly - values - the array of length 3 containing xyz in orderisDirty - copy -
protected Point2i(boolean readOnly,
Tuple2i tuple)
readOnly - tuple - the Point3i containing the initialization x y z dataprotected Point2i(boolean readOnly)
readOnly -
public Point2i(int x,
int y)
x - the x coordinatey - the y coordinatepublic Point2i(int[] values)
values - the array of length 3 containing xyz in orderpublic Point2i(Tuple2i tuple)
tuple - the Point3i containing the initialization x y z datapublic Point2i()
| Method Detail |
|---|
public Point2i clone()
clone in class Tuple2iCloneablepublic Point2i asReadOnly()
asReadOnly in class Tuple2iTupleNi.getReadOnly()public Point2i getReadOnly()
getReadOnly in class Tuple2iTupleNi.asReadOnly()
public static Point2i newReadOnly(int x,
int y)
x - the x coordinatey - the y coordinatepublic static Point2i newReadOnly(int[] values)
values - the array of length 3 containing xyz in orderpublic static Point2i newReadOnly(Tuple2i tuple)
tuple - the Point3i containing the initialization x y z datapublic static Point2i newReadOnly()
public static Point2i fromPool()
public static Point2i fromPool(int x,
int y)
public static Point2i fromPool(Tuple2i tuple)
public static void toPool(Point2i o)
o -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||