Class AIMeshMorphKey

All Implemented Interfaces:
AutoCloseable, NativeResource, Pointer

public class AIMeshMorphKey extends Struct<AIMeshMorphKey> implements NativeResource

 struct aiMeshMorphKey {
     double mTime;
     unsigned int * mValues;
     double * mWeights;
     unsigned int mNumValuesAndWeights;
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • MTIME

      public static final int MTIME
      The struct member offsets.
    • MVALUES

      public static final int MVALUES
      The struct member offsets.
    • MWEIGHTS

      public static final int MWEIGHTS
      The struct member offsets.
    • MNUMVALUESANDWEIGHTS

      public static final int MNUMVALUESANDWEIGHTS
      The struct member offsets.
  • Constructor Details

    • AIMeshMorphKey

      public AIMeshMorphKey(ByteBuffer container)
      Creates a AIMeshMorphKey instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

      The created instance holds a strong reference to the container object.

  • Method Details

    • sizeof

      public int sizeof()
      Description copied from class: Struct
      Returns sizeof(struct).
      Specified by:
      sizeof in class Struct<AIMeshMorphKey>
    • mTime

      public double mTime()
      Returns:
      the value of the mTime field.
    • mValues

      public IntBuffer mValues()
      Returns:
      a IntBuffer view of the data pointed to by the mValues field.
    • mWeights

      public DoubleBuffer mWeights()
      Returns:
      a DoubleBuffer view of the data pointed to by the mWeights field.
    • mNumValuesAndWeights

      public int mNumValuesAndWeights()
      Returns:
      the value of the mNumValuesAndWeights field.
    • mTime

      public AIMeshMorphKey mTime(double value)
      Sets the specified value to the mTime field.
    • mValues

      public AIMeshMorphKey mValues(IntBuffer value)
      Sets the address of the specified IntBuffer to the mValues field.
    • mWeights

      public AIMeshMorphKey mWeights(DoubleBuffer value)
      Sets the address of the specified DoubleBuffer to the mWeights field.
    • mNumValuesAndWeights

      public AIMeshMorphKey mNumValuesAndWeights(int value)
      Sets the specified value to the mNumValuesAndWeights field.
    • set

      public AIMeshMorphKey set(double mTime, IntBuffer mValues, DoubleBuffer mWeights, int mNumValuesAndWeights)
      Initializes this struct with the specified values.
    • set

      public AIMeshMorphKey set(AIMeshMorphKey src)
      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

      public static AIMeshMorphKey malloc()
      Returns a new AIMeshMorphKey instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

      public static AIMeshMorphKey calloc()
      Returns a new AIMeshMorphKey instance allocated with memCalloc. The instance must be explicitly freed.
    • create

      public static AIMeshMorphKey create()
      Returns a new AIMeshMorphKey instance allocated with BufferUtils.
    • create

      public static AIMeshMorphKey create(long address)
      Returns a new AIMeshMorphKey instance for the specified memory address.
    • createSafe

      public static @Nullable AIMeshMorphKey createSafe(long address)
      Like create, but returns null if address is NULL.
    • malloc

      public static AIMeshMorphKey.Buffer malloc(int capacity)
      Returns a new AIMeshMorphKey.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static AIMeshMorphKey.Buffer calloc(int capacity)
      Returns a new AIMeshMorphKey.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static AIMeshMorphKey.Buffer create(int capacity)
      Returns a new AIMeshMorphKey.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static AIMeshMorphKey.Buffer create(long address, int capacity)
      Create a AIMeshMorphKey.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable AIMeshMorphKey.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • malloc

      public static AIMeshMorphKey malloc(MemoryStack stack)
      Returns a new AIMeshMorphKey instance allocated on the specified MemoryStack.
      Parameters:
      stack - the stack from which to allocate
    • calloc

      public static AIMeshMorphKey calloc(MemoryStack stack)
      Returns a new AIMeshMorphKey instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      stack - the stack from which to allocate
    • malloc

      public static AIMeshMorphKey.Buffer malloc(int capacity, MemoryStack stack)
      Returns a new AIMeshMorphKey.Buffer instance allocated on the specified MemoryStack.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • calloc

      public static AIMeshMorphKey.Buffer calloc(int capacity, MemoryStack stack)
      Returns a new AIMeshMorphKey.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • nmTime

      public static double nmTime(long struct)
      Unsafe version of mTime().
    • nmValues

      public static IntBuffer nmValues(long struct)
      Unsafe version of mValues.
    • nmWeights

      public static DoubleBuffer nmWeights(long struct)
      Unsafe version of mWeights.
    • nmNumValuesAndWeights

      public static int nmNumValuesAndWeights(long struct)
      Unsafe version of mNumValuesAndWeights().
    • nmTime

      public static void nmTime(long struct, double value)
      Unsafe version of mTime.
    • nmValues

      public static void nmValues(long struct, IntBuffer value)
      Unsafe version of mValues.
    • nmWeights

      public static void nmWeights(long struct, DoubleBuffer value)
      Unsafe version of mWeights.
    • nmNumValuesAndWeights

      public static void nmNumValuesAndWeights(long struct, int value)
      Sets the specified value to the mNumValuesAndWeights field of the specified struct.
    • validate

      public static void validate(long struct)
      Validates pointer members that should not be NULL.
      Parameters:
      struct - the struct to validate