Class SbVec4ub

java.lang.Object
com.openinventor.inventor.SbBasic
com.openinventor.inventor.SbVec4ub

public class SbVec4ub extends SbBasic
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 Details

    • array

      public final byte[] array
  • Constructor Details

    • SbVec4ub

      public SbVec4ub(byte c0, byte c1, byte c2, byte c3)
    • SbVec4ub

      public SbVec4ub()
    • SbVec4ub

      public SbVec4ub(SbVec4ub copyFrom)
    • SbVec4ub

      public SbVec4ub(byte[] components)
  • Method Details

    • getValue

      public byte[] getValue()
    • setValue

      public void setValue(SbVec4ub copyFrom)
    • setValue

      public SbVec4ub setValue(byte[] components, int startIndex)
    • setValueAt

      public void setValueAt(int index, byte value)
    • setValue

      public SbVec4ub setValue(byte[] components)
    • getValueAt

      public byte getValueAt(int index)
    • setValue

      public SbVec4ub setValue(byte c0, byte c1, byte c2, byte c3)
    • 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

      public int dot(SbVec4ub v)
      Returns dot (inner) product of vector and another vector.
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • toArray

      public static SbVec4ub[] toArray(long nativeArray, long length)
    • clamp

      public void clamp(byte a, byte b)
      Clamp each component between a and b.
    • minus

      public SbVec4ub minus(SbVec4ub v2)
      Component-wise binary vector subtraction operator.
    • multiply

      public void multiply(double d)
      Component-wise scalar multiplication operator.
    • times

      public SbVec4ub times(int d)
      Component-wise binary scalar multiplication operator.
    • times

      public SbVec4ub times(double d)
      Component-wise binary scalar multiplication operator.
    • substract

      public void substract(SbVec4ub u)
      Component-wise vector subtraction operator.
    • divide

      public void divide(double d)
      Component-wise scalar division operator.
    • add

      public void add(SbVec4ub u)
      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

      public SbVec4ub plus(SbVec4ub v2)
      Component-wise binary vector addition operator.
    • negate

      public void negate()
      Negates each component of vector in place.
    • over

      public SbVec4ub over(double d)
      Component-wise binary scalar division operator.
    • over

      public SbVec4ub over(int d)
      Component-wise binary scalar division operator.