Class SoSFMatrix


  • public class SoSFMatrix
    extends SoSField
    Field containing a 4x4 matrix. A field containing a transformation matrix (an SbMatrix).

    SoSFMatrixs are written to file as 16 floating point numbers separated by whitespace. For example, an identity matrix is written as:

       1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1

    See Also:
    SoField, SoSField, SoMFMatrix, SbMatrix
    • Method Detail

      • setValue

        public void setValue​(SbMatrix newValue)
        Sets this field to newValue.
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class SoField
      • setValue

        public void setValue​(SbMatrixd md)
        Convenience method that allows you to specify a field value using a double precision variable. Note that Open Inventor fields still store only single precision values, not double precision values. The specified value is converted to single precision, then stored.
      • setValue

        public void setValue​(float a11,
                             float a12,
                             float a13,
                             float a14,
                             float a21,
                             float a22,
                             float a23,
                             float a24,
                             float a31,
                             float a32,
                             float a33,
                             float a34,
                             float a41,
                             float a42,
                             float a43,
                             float a44)
        Sets this field to contain the matrix given by the 16 values. For a translation matrix, the x, y and z translations should be in the a41, a42, and a43 arguments.
      • getValue

        public SbMatrix getValue()
        Returns this field's value.