public class Vector2d
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
swigCMemOwn |
Constructor and Description |
---|
Vector2d() |
Vector2d(double[] data) |
Vector2d(double x,
double y) |
Vector2d(long cPtr,
boolean cMemoryOwn) |
Modifier and Type | Method and Description |
---|---|
Vector2d |
add(Vector2d other)
Vector sum.
|
static long[] |
cArrayUnwrap(Vector2d[] arrayWrapper) |
static Vector2d[] |
cArrayWrap(long[] cArray,
boolean cMemoryOwn) |
void |
delete() |
double |
dot(Vector2d other)
Dot product.
|
protected void |
finalize() |
static long |
getCPtr(Vector2d obj) |
double[] |
getData() |
double |
getX() |
double |
getY() |
Vector2d |
mul(double c)
Multiplication by scalar.
|
double |
norm()
Vector norm.
|
Vector2d |
normalized()
Normalized vector.
|
void |
setX(double value) |
void |
setY(double value) |
Vector2d |
sub(Vector2d other)
Vector difference.
|
public Vector2d(long cPtr, boolean cMemoryOwn)
public Vector2d()
public Vector2d(double x, double y)
public Vector2d(double[] data)
public static long getCPtr(Vector2d obj)
protected void finalize()
finalize
in class java.lang.Object
public void delete()
public static long[] cArrayUnwrap(Vector2d[] arrayWrapper)
public static Vector2d[] cArrayWrap(long[] cArray, boolean cMemoryOwn)
public double getX()
public double getY()
public void setX(double value)
public void setY(double value)
public double[] getData()
public double dot(Vector2d other)
public Vector2d mul(double c)
public double norm()
public Vector2d normalized()