|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.metaio.sdk.jni.Vector2d
public class Vector2d
Structure that defines a 2D vector.
Constructor Summary | |
---|---|
Vector2d()
|
|
Vector2d(float _n)
|
|
Vector2d(float _x,
float _y)
|
|
Vector2d(long cPtr,
boolean cMemoryOwn)
|
|
Vector2d(Vector2d other)
|
Method Summary | |
---|---|
Vector2d |
add(Vector2d rhs)
|
Vector2d |
cwiseProduct(Vector2d rhs)
|
Vector2d |
cwiseQuotient(Vector2d rhs)
|
void |
delete()
|
float |
dot(Vector2d rhs)
|
static long |
getCPtr(Vector2d obj)
|
float |
getX()
x component of the vector |
float |
getY()
y component of the vector |
boolean |
isNull()
true if null vector, else false |
Vector2d |
multiply(float rhs)
|
float |
norm()
Result of the operation |
void |
setX(float value)
x component of the vector |
void |
setY(float value)
y component of the vector |
float |
squaredNorm()
Result of the operation |
Vector2d |
subtract(Vector2d rhs)
|
String |
toString()
|
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Vector2d(long cPtr, boolean cMemoryOwn)
public Vector2d()
public Vector2d(float _n)
_n
- x and y components of the vectorpublic Vector2d(float _x, float _y)
_x
- x component of the vector_y
- y component of the vectorpublic Vector2d(Vector2d other)
Method Detail |
---|
public static long getCPtr(Vector2d obj)
public void delete()
public void setX(float value)
public float getX()
public void setY(float value)
public float getY()
public Vector2d add(Vector2d rhs)
public Vector2d subtract(Vector2d rhs)
public Vector2d cwiseProduct(Vector2d rhs)
rhs
- Right-hand-side of the operation
Result of the operationpublic Vector2d cwiseQuotient(Vector2d rhs)
rhs
- Right-hand-side of the operation
Result of the operationpublic Vector2d multiply(float rhs)
public float dot(Vector2d rhs)
rhs
- Right-hand-side of the operation
Result of the operationpublic float norm()
public float squaredNorm()
public boolean isNull()
public String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |