Class SoCoordinateElement


public class SoCoordinateElement extends SoReplacedElement
Stores the current coordinates. This element stores the current coordinates. Coordinates may be specified as 3-D or 4-D vectors. This element remembers the last type of value stored.

This class allows read-only access to the top element in the state to make accessing several values in it more efficient. Individual values must be accessed through this instance.

See Also:
  • Method Details Link icon

    • set4 Link icon

      public static void set4(SoState state, SoNode node, SbVec4f[] coords)
      Sets the current coordinates in the state as 4-vectors.
    • get3 Link icon

      public SbVec3f get3(int index)
      Returns the indexed coordinate from an element as a 3-vector, converting if necessary. A returned reference may be invalid after the next call to this method or the get4() method.
    • getClassStackIndex Link icon

      @Deprecated(since="9.3.0.0") public static int getClassStackIndex()
      Deprecated.
      As of Open Inventor 9.3.0.0. replaced by SoElement.getClassStackIndex(Class)
      Returns the stack id for this element. ] *
    • set3 Link icon

      public static void set3(SoState state, SoNode node, SbVec3f[] coords)
      Sets the current coordinates in the state as 3-vectors.
    • getNum Link icon

      public int getNum()
      Returns the number of coordinate points in an instance.
    • getDefault3 Link icon

      public static SbVec3f getDefault3()
      Returns the default 3-D coordinate.
    • getDefault4 Link icon

      public static SbVec4f getDefault4()
      Returns the default 4-D coordinate.
    • get4 Link icon

      public SbVec4f get4(int index)
      Returns the indexed coordinate from an element as a 4-vector, converting if necessary. A returned reference may be invalid after the next call to this method or the get3() method.
    • is3D Link icon

      public boolean is3D()
      Returns true if the coordinates were specified as 3-vectors, false if 4-vectors.
    • getInstance Link icon

      public static SoCoordinateElement getInstance(SoState state)
      Returns the top (current) instance of the element in the state.