Class PMatrixByteBuffered4x4s64<A,B>

java.lang.Object
com.io7m.jtensors.storage.bytebuffered.PMatrixByteBuffered4x4s64<A,B>
Type Parameters:
A - A phantom type parameter (possibly representing a source coordinate system)
B - A phantom type parameter (possibly representing a target coordinate system)
All Implemented Interfaces:
PMatrixReadable4x4DType<A,B>, MatrixReadable4x4DType, MatrixReadableDType, MatrixStorageType, PMatrixStorage4x4Type<A,B>, MatrixStorage4x4Type, MatrixByteBufferedType, PMatrixByteBuffered4x4Type<A,B>, TensorByteBufferedType

public final class PMatrixByteBuffered4x4s64<A,B> extends Object implements PMatrixByteBuffered4x4Type<A,B>

A storage matrix.

Storage component type: double

Storage component count: 4x4

  • Method Details

    • createWithBase

      public static <A,B> PMatrixByteBuffered4x4s64<A,B> createWithBase(ByteBuffer b, com.io7m.mutable.numbers.core.MutableLongType base, int offset)

      Return a new vector that is backed by the given byte buffer b

      The data for the instance will be taken from the data at the current value of base.get() + offset, each time a field is requested or set.

      No initialization of the data is performed.

      Type Parameters:
      A - A phantom type parameter (possibly representing a source coordinate system)
      B - A phantom type parameter (possibly representing a target coordinate system)
      Parameters:
      b - The byte buffer
      base - The base address
      offset - A constant offset
      Returns:
      A new buffered vector
    • componentCount

      protected int componentCount()
    • r0c0

      public double r0c0()
      Specified by:
      r0c0 in interface MatrixReadable4x4DType
      Returns:
      The value at row 0 column 0
    • r0c1

      public double r0c1()
      Specified by:
      r0c1 in interface MatrixReadable4x4DType
      Returns:
      The value at row 0 column 1
    • r0c2

      public double r0c2()
      Specified by:
      r0c2 in interface MatrixReadable4x4DType
      Returns:
      The value at row 0 column 2
    • r0c3

      public double r0c3()
      Specified by:
      r0c3 in interface MatrixReadable4x4DType
      Returns:
      The value at row 0 column 3
    • r1c0

      public double r1c0()
      Specified by:
      r1c0 in interface MatrixReadable4x4DType
      Returns:
      The value at row 1 column 0
    • r1c1

      public double r1c1()
      Specified by:
      r1c1 in interface MatrixReadable4x4DType
      Returns:
      The value at row 1 column 1
    • r1c2

      public double r1c2()
      Specified by:
      r1c2 in interface MatrixReadable4x4DType
      Returns:
      The value at row 1 column 2
    • r1c3

      public double r1c3()
      Specified by:
      r1c3 in interface MatrixReadable4x4DType
      Returns:
      The value at row 1 column 3
    • r2c0

      public double r2c0()
      Specified by:
      r2c0 in interface MatrixReadable4x4DType
      Returns:
      The value at row 2 column 0
    • r2c1

      public double r2c1()
      Specified by:
      r2c1 in interface MatrixReadable4x4DType
      Returns:
      The value at row 2 column 1
    • r2c2

      public double r2c2()
      Specified by:
      r2c2 in interface MatrixReadable4x4DType
      Returns:
      The value at row 2 column 2
    • r2c3

      public double r2c3()
      Specified by:
      r2c3 in interface MatrixReadable4x4DType
      Returns:
      The value at row 2 column 3
    • r3c0

      public double r3c0()
      Specified by:
      r3c0 in interface MatrixReadable4x4DType
      Returns:
      The value at row 3 column 0
    • r3c1

      public double r3c1()
      Specified by:
      r3c1 in interface MatrixReadable4x4DType
      Returns:
      The value at row 3 column 1
    • r3c2

      public double r3c2()
      Specified by:
      r3c2 in interface MatrixReadable4x4DType
      Returns:
      The value at row 3 column 2
    • r3c3

      public double r3c3()
      Specified by:
      r3c3 in interface MatrixReadable4x4DType
      Returns:
      The value at row 3 column 3
    • setPMatrix4x4D

      public void setPMatrix4x4D(PMatrix4x4D<A,B> m)
      Description copied from interface: PMatrixStorage4x4Type
      Set the components from the given matrix.
      Specified by:
      setPMatrix4x4D in interface PMatrixStorage4x4Type<A,B>
      Parameters:
      m - The source matrix
    • setPMatrix4x4F

      public void setPMatrix4x4F(PMatrix4x4F<A,B> m)
      Description copied from interface: PMatrixStorage4x4Type
      Set the components from the given matrix.
      Specified by:
      setPMatrix4x4F in interface PMatrixStorage4x4Type<A,B>
      Parameters:
      m - The source matrix
    • setMatrix4x4D

      public void setMatrix4x4D(Matrix4x4D m)
      Description copied from interface: MatrixStorage4x4Type
      Set the components from the given matrix.
      Specified by:
      setMatrix4x4D in interface MatrixStorage4x4Type
      Parameters:
      m - The source matrix
    • setMatrix4x4F

      public void setMatrix4x4F(Matrix4x4F m)
      Description copied from interface: MatrixStorage4x4Type
      Set the components from the given matrix.
      Specified by:
      setMatrix4x4F in interface MatrixStorage4x4Type
      Parameters:
      m - The source matrix
    • componentBytes

      protected final int componentBytes()
    • byteBuffer

      public final ByteBuffer byteBuffer()
      Specified by:
      byteBuffer in interface TensorByteBufferedType
      Returns:
      The byte buffer that backs the tensor
    • byteOffset

      public final long byteOffset()
      Specified by:
      byteOffset in interface TensorByteBufferedType
      Returns:
      The byte offset of the current tensor
    • offset

      public final int offset()
      Specified by:
      offset in interface TensorByteBufferedType
      Returns:
      A constant offset added to TensorByteBufferedType.byteOffset().
    • sizeBytes

      public final int sizeBytes()
      Specified by:
      sizeBytes in interface TensorByteBufferedType
      Returns:
      The size of a single tensor in bytes
    • byteOffsetForIndex

      protected final int byteOffsetForIndex(int component_index)