Package com.openinventor.inventor
Class SbVec4ub
java.lang.Object
com.openinventor.inventor.SbBasic
com.openinventor.inventor.SbVec4ub
4D vector class.
4D vector class used to store 4D integer vectors and points. This class is used throughout Open Inventor for arguments and return values.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Component-wise vector addition operator.void
clamp
(byte a, byte b) Clamp each component between a and b.void
divide
(double d) Component-wise scalar division operator.void
divide
(int d) Component-wise scalar division operator.int
Returns dot (inner) product of vector and another vector.boolean
byte[]
getValue()
byte
getValueAt
(int index) byte
getW()
byte
getX()
byte
getY()
byte
getZ()
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.over
(double d) Component-wise binary scalar division operator.over
(int d) Component-wise binary scalar division operator.Component-wise binary vector addition operator.setValue
(byte[] components) setValue
(byte[] components, int startIndex) setValue
(byte c0, byte c1, byte c2, byte c3) void
void
setValueAt
(int index, byte value) void
setW
(byte value) void
setX
(byte value) void
setY
(byte value) void
setZ
(byte value) void
Component-wise vector subtraction operator.times
(double d) Component-wise binary scalar multiplication operator.times
(int d) Component-wise binary scalar multiplication operator.static SbVec4ub[]
toArray
(long nativeArray, long length)
-
Field Details
-
array
public final byte[] array
-
-
Constructor Details
-
SbVec4ub
public SbVec4ub(byte c0, byte c1, byte c2, byte c3) -
SbVec4ub
public SbVec4ub() -
SbVec4ub
-
SbVec4ub
public SbVec4ub(byte[] components)
-
-
Method Details
-
getValue
public byte[] getValue() -
setValue
-
setValue
-
setValueAt
public void setValueAt(int index, byte value) -
setValue
-
getValueAt
public byte getValueAt(int index) -
setValue
-
setZ
public void setZ(byte value) -
getW
public byte getW() -
setW
public void setW(byte value) -
getZ
public byte getZ() -
getY
public byte getY() -
getX
public byte getX() -
setX
public void setX(byte value) -
setY
public void setY(byte value) -
dot
Returns dot (inner) product of vector and another vector. -
equals
-
toArray
-
clamp
public void clamp(byte a, byte b) Clamp each component between a and b. -
minus
Component-wise binary vector subtraction operator. -
multiply
public void multiply(double d) Component-wise scalar multiplication operator. -
times
Component-wise binary scalar multiplication operator. -
times
Component-wise binary scalar multiplication operator. -
substract
Component-wise vector subtraction operator. -
divide
public void divide(double d) Component-wise scalar division operator. -
add
Component-wise vector addition operator. -
divide
public void divide(int d) Component-wise scalar division operator. -
multiply
public void multiply(int d) Component-wise scalar multiplication operator. -
plus
Component-wise binary vector addition operator. -
negate
public void negate()Negates each component of vector in place. -
over
Component-wise binary scalar division operator. -
over
Component-wise binary scalar division operator.
-