Package com.openinventor.inventor
Class SbVec2i32
- java.lang.Object
-
- com.openinventor.inventor.SbBasic
-
- com.openinventor.inventor.SbVec2i32
-
public class SbVec2i32 extends SbBasic
2D vector class. 2D vector class used to store 2D vectors and points. This class is used throughout Open Inventor for arguments and return values.
-
-
Field Summary
Fields Modifier and Type Field Description int[]
array
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(SbVec2i32 u)
Component-wise vector addition operator.void
divide(double d)
Component-wise scalar division operator.void
divide(int d)
Component-wise scalar division operator.int
dot(SbVec2i32 v)
Returns dot (inner) product of vector and another vector.boolean
equals(java.lang.Object obj)
int[]
getValue()
int
getValueAt(int index)
int
getX()
int
getY()
SbVec2i32
minus(SbVec2i32 v2)
Component-wise binary vector subtraction operator.void
multiply(double d)
Component-wise scalar multiplication operator.void
multiply(int d)
Component-wise scalar multiplication operator.void
negate()
Negates each component of vector in place.SbVec2i32
over(double d)
Component-wise binary scalar division operator.SbVec2i32
over(int d)
Component-wise binary scalar division operator.SbVec2i32
plus(SbVec2i32 v2)
Component-wise binary vector addition operator.SbVec2i32
setValue(int[] components)
SbVec2i32
setValue(int[] components, int startIndex)
SbVec2i32
setValue(int c0, int c1)
void
setValue(SbVec2i32 copyFrom)
void
setValueAt(int index, int value)
void
setX(int value)
void
setY(int value)
void
substract(SbVec2i32 u)
Component-wise vector subtraction operator.SbVec2i32
times(double d)
Component-wise binary scalar multiplication operator.SbVec2i32
times(int d)
Component-wise binary scalar multiplication operator.static SbVec2i32[]
toArray(long nativeArray, long length)
-
-
-
Constructor Detail
-
SbVec2i32
public SbVec2i32()
-
SbVec2i32
public SbVec2i32(int[] components)
-
SbVec2i32
public SbVec2i32(int c0, int c1)
-
SbVec2i32
public SbVec2i32(SbVec2i32 copyFrom)
-
-
Method Detail
-
setValue
public SbVec2i32 setValue(int[] components, int startIndex)
-
setValue
public SbVec2i32 setValue(int c0, int c1)
-
setValue
public void setValue(SbVec2i32 copyFrom)
-
setValueAt
public void setValueAt(int index, int value)
-
getValueAt
public int getValueAt(int index)
-
getValue
public int[] getValue()
-
getX
public int getX()
-
getY
public int getY()
-
setValue
public SbVec2i32 setValue(int[] components)
-
setX
public void setX(int value)
-
setY
public void setY(int value)
-
multiply
public void multiply(int d)
Component-wise scalar multiplication operator.
-
over
public SbVec2i32 over(double d)
Component-wise binary scalar division operator.
-
toArray
public static SbVec2i32[] toArray(long nativeArray, long length)
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
multiply
public void multiply(double d)
Component-wise scalar multiplication operator.
-
dot
public int dot(SbVec2i32 v)
Returns dot (inner) product of vector and another vector.
-
divide
public void divide(int d)
Component-wise scalar division operator.
-
negate
public void negate()
Negates each component of vector in place.
-
times
public SbVec2i32 times(int d)
Component-wise binary scalar multiplication operator.
-
over
public SbVec2i32 over(int d)
Component-wise binary scalar division operator.
-
times
public SbVec2i32 times(double d)
Component-wise binary scalar multiplication operator.
-
substract
public void substract(SbVec2i32 u)
Component-wise vector subtraction operator.
-
divide
public void divide(double d)
Component-wise scalar division operator.
-
add
public void add(SbVec2i32 u)
Component-wise vector addition operator.
-
-