|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xbig.base.NativeObject
org.ogre4j.Vector2
public class Vector2
| Field Summary |
|---|
| Fields inherited from class org.xbig.base.NativeObject |
|---|
deleted, object, remote |
| Constructor Summary | |
|---|---|
|
Vector2()
|
|
Vector2(float fX,
float fY)
|
|
Vector2(FloatPointer r)
|
|
Vector2(InstancePointer p)
This constructor is public for internal useage only! |
protected |
Vector2(InstancePointer p,
boolean remote)
Creates a Java wrapper object for an existing C++ object. |
|
Vector2(int afCoordinate)
|
|
Vector2(WithoutNativeObject val)
Allows creation of Java objects without C++ objects. |
| Method Summary | |
|---|---|
float |
crossProduct(IVector2 rkVector)
Calculates the 2 dimensional cross-product of 2 vectors, which results in a single floating point value which is 2 times the area of the triangle. |
void |
delete()
Deletes the corresponding C++ object. |
float |
dotProduct(IVector2 vec)
Calculates the dot (scalar) product of this vector with another. |
void |
finalize()
|
static IVector2 |
getNEGATIVE_UNIT_X()
|
static IVector2 |
getNEGATIVE_UNIT_Y()
|
static IVector2 |
getUNIT_SCALE()
|
static IVector2 |
getUNIT_X()
|
static IVector2 |
getUNIT_Y()
|
float |
getx()
|
float |
gety()
|
static IVector2 |
getZERO()
|
boolean |
isZeroLength()
Returns true if this vector is zero length. |
float |
length()
Returns the length (magnitude) of the vector. |
void |
makeCeil(IVector2 cmp)
Sets this vector's components to the maximum of its own and the ones of the passed in vector. |
void |
makeFloor(IVector2 cmp)
Sets this vector's components to the minimum of its own and the ones of the passed in vector. |
void |
midPoint(IVector2 returnValue,
IVector2 vec)
Returns a vector at a point half way between this and the passed in vector. |
float |
normalise()
Normalises the vector. |
void |
normalisedCopy(IVector2 returnValue)
As normalise, except that this vector is unaffected and the normalised vector is returned as a copy. |
IVector2 |
operatorAddition()
|
void |
operatorAddition(IVector2 returnValue,
IVector2 rkVector)
|
IVector2 |
operatorAssignment(float fScalar)
|
IVector2 |
operatorAssignment(IVector2 rkVector)
Assigns the value of the other vector. |
IVector2 |
operatorDecrementAndAssign(float fScaler)
|
IVector2 |
operatorDecrementAndAssign(IVector2 rkVector)
|
IVector2 |
operatorDivideAndAssign(float fScalar)
|
IVector2 |
operatorDivideAndAssign(IVector2 rkVector)
|
void |
operatorDivision(IVector2 returnValue,
float fScalar)
|
void |
operatorDivision(IVector2 returnValue,
IVector2 rhs)
|
boolean |
operatorEqual(IVector2 rkVector)
|
boolean |
operatorGreaterThan(IVector2 rhs)
Returns true if the vector's scalar components are all smaller that the ones of the vector it is compared against. |
IVector2 |
operatorIncrementAndAssign(float fScaler)
|
IVector2 |
operatorIncrementAndAssign(IVector2 rkVector)
|
float |
operatorIndex_const(int i)
|
FloatPointer |
operatorIndex(int i)
|
boolean |
operatorLessThan(IVector2 rhs)
Returns true if the vector's scalar components are all greater that the ones of the vector it is compared against. |
void |
operatorMultiplication(IVector2 returnValue,
float fScalar)
|
void |
operatorMultiplication(IVector2 returnValue,
IVector2 rhs)
|
IVector2 |
operatorMultiplyAndAssign(float fScalar)
|
IVector2 |
operatorMultiplyAndAssign(IVector2 rkVector)
|
boolean |
operatorNotEqual(IVector2 rkVector)
|
void |
operatorSubtraction(IVector2 returnValue)
|
void |
operatorSubtraction(IVector2 returnValue,
IVector2 rkVector)
|
void |
perpendicular(IVector2 returnValue)
Generates a vector perpendicular to this vector (eg an 'up' vector). |
FloatPointer |
ptr_const()
|
FloatPointer |
ptr()
|
void |
randomDeviant(IVector2 returnValue,
float angle)
Generates a new random vector which deviates from this vector by a given angle in a random direction. |
void |
reflect(IVector2 returnValue,
IVector2 normal)
Calculates a reflection vector to the plane with the given normal . |
void |
setx(float _jni_value_)
|
void |
sety(float _jni_value_)
|
float |
squaredLength()
Returns the square of the length(magnitude) of the vector. |
| Methods inherited from class org.xbig.base.NativeObject |
|---|
disconnectFromNativeObject, equals, getInstancePointer, hashCode, setInstancePointer, setInstancePointer, setInstancePointer, toString |
| Methods inherited from class java.lang.Object |
|---|
clone, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.xbig.base.INativeObject |
|---|
disconnectFromNativeObject, getInstancePointer, setInstancePointer, setInstancePointer, setInstancePointer |
| Constructor Detail |
|---|
public Vector2(InstancePointer p)
protected Vector2(InstancePointer p,
boolean remote)
public Vector2(WithoutNativeObject val)
WithoutNativeObject,
INativeObject.disconnectFromNativeObject()public Vector2()
public Vector2(float fX,
float fY)
public Vector2(int afCoordinate)
public Vector2(FloatPointer r)
| Method Detail |
|---|
public void delete()
INativeObjectSubclasses must implement this but if the native instance was created by the underlying library the native call to dispose must not happen!
delete in interface INativeObjectdelete in class NativeObject#remotepublic void finalize()
finalize in class NativeObjectpublic float operatorIndex_const(int i)
operatorIndex_const in interface IVector2public FloatPointer operatorIndex(int i)
operatorIndex in interface IVector2public FloatPointer ptr()
ptr in interface IVector2public FloatPointer ptr_const()
ptr_const in interface IVector2public IVector2 operatorAssignment(IVector2 rkVector)
operatorAssignment in interface IVector2public IVector2 operatorAssignment(float fScalar)
operatorAssignment in interface IVector2public boolean operatorEqual(IVector2 rkVector)
operatorEqual in interface IVector2public boolean operatorNotEqual(IVector2 rkVector)
operatorNotEqual in interface IVector2
public void operatorAddition(IVector2 returnValue,
IVector2 rkVector)
operatorAddition in interface IVector2
public void operatorSubtraction(IVector2 returnValue,
IVector2 rkVector)
operatorSubtraction in interface IVector2
public void operatorMultiplication(IVector2 returnValue,
float fScalar)
operatorMultiplication in interface IVector2
public void operatorMultiplication(IVector2 returnValue,
IVector2 rhs)
operatorMultiplication in interface IVector2
public void operatorDivision(IVector2 returnValue,
float fScalar)
operatorDivision in interface IVector2
public void operatorDivision(IVector2 returnValue,
IVector2 rhs)
operatorDivision in interface IVector2public IVector2 operatorAddition()
operatorAddition in interface IVector2public void operatorSubtraction(IVector2 returnValue)
operatorSubtraction in interface IVector2public IVector2 operatorIncrementAndAssign(IVector2 rkVector)
operatorIncrementAndAssign in interface IVector2public IVector2 operatorIncrementAndAssign(float fScaler)
operatorIncrementAndAssign in interface IVector2public IVector2 operatorDecrementAndAssign(IVector2 rkVector)
operatorDecrementAndAssign in interface IVector2public IVector2 operatorDecrementAndAssign(float fScaler)
operatorDecrementAndAssign in interface IVector2public IVector2 operatorMultiplyAndAssign(float fScalar)
operatorMultiplyAndAssign in interface IVector2public IVector2 operatorMultiplyAndAssign(IVector2 rkVector)
operatorMultiplyAndAssign in interface IVector2public IVector2 operatorDivideAndAssign(float fScalar)
operatorDivideAndAssign in interface IVector2public IVector2 operatorDivideAndAssign(IVector2 rkVector)
operatorDivideAndAssign in interface IVector2public float length()
length in interface IVector2public float squaredLength()
squaredLength in interface IVector2public float dotProduct(IVector2 vec)
dotProduct in interface IVector2public float normalise()
normalise in interface IVector2
public void midPoint(IVector2 returnValue,
IVector2 vec)
midPoint in interface IVector2public boolean operatorLessThan(IVector2 rhs)
operatorLessThan in interface IVector2public boolean operatorGreaterThan(IVector2 rhs)
operatorGreaterThan in interface IVector2public void makeFloor(IVector2 cmp)
makeFloor in interface IVector2public void makeCeil(IVector2 cmp)
makeCeil in interface IVector2public void perpendicular(IVector2 returnValue)
perpendicular in interface IVector2public float crossProduct(IVector2 rkVector)
crossProduct in interface IVector2
public void randomDeviant(IVector2 returnValue,
float angle)
randomDeviant in interface IVector2public boolean isZeroLength()
isZeroLength in interface IVector2public void normalisedCopy(IVector2 returnValue)
normalisedCopy in interface IVector2
public void reflect(IVector2 returnValue,
IVector2 normal)
reflect in interface IVector2public float getx()
getx in interface IVector2public void setx(float _jni_value_)
setx in interface IVector2public float gety()
gety in interface IVector2public void sety(float _jni_value_)
sety in interface IVector2public static IVector2 getZERO()
public static IVector2 getUNIT_X()
public static IVector2 getUNIT_Y()
public static IVector2 getNEGATIVE_UNIT_X()
public static IVector2 getNEGATIVE_UNIT_Y()
public static IVector2 getUNIT_SCALE()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||