Package org.lwjgl.assimp
Class AIAnimation
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.assimp.AIAnimation
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class AIAnimation extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
An animation consists of keyframe data for a number of nodes. For each node affected by the animation a separate series of data is given.Member documentation
mName
– The name of the animation. If the modeling package this data was exported from does support only a single animation channel, this name is usually empty (length is zero).mDuration
– Duration of the animation in ticks.mTicksPerSecond
– Ticks per second. 0 if not specified in the imported filemNumChannels
– The number of bone animation channels. Each channel affects a single node.mChannels
– The node animation channels. Each channel affects a single node. The array ismNumChannels
in size.mNumMeshChannels
– The number of mesh animation channels. Each channel affects a single mesh and defines vertex-based animation.mMeshChannels
– The mesh animation channels. Each channel affects a single mesh. The array ismNumMeshChannels
in size.mNumMorphMeshChannels
– the number of mesh animation channels. Each channel affects a single mesh and defines morphing animation.mMorphMeshChannels
– the morph mesh animation channels. Each channel affects a single mesh. The array ismNumMorphMeshChannels
in size.
Layout
struct aiAnimation {
struct aiString
mName; double mDuration; double mTicksPerSecond; unsigned int mNumChannels;struct aiNodeAnim
** mChannels; unsigned int mNumMeshChannels;struct aiMeshAnim
** mMeshChannels; unsigned int mNumMorphMeshChannels;struct aiMeshMorphAnim
** mMorphMeshChannels; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AIAnimation.Buffer
An array ofAIAnimation
structs.
-
Field Summary
Fields Modifier and Type Field Description static int
ALIGNOF
The struct alignment in bytes.static int
MCHANNELS
MDURATION
MMESHCHANNELS
MMORPHMESHCHANNELS
MNAME
MNUMCHANNELS
MNUMMESHCHANNELS
MNUMMORPHMESHCHANNELS
MTICKSPERSECONDThe struct member offsets.static int
SIZEOF
The struct size in bytes.
-
Constructor Summary
Constructors Constructor Description AIAnimation(java.nio.ByteBuffer container)
Creates aAIAnimation
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static AIAnimation
calloc()
Returns a newAIAnimation
instance allocated withmemCalloc
.static AIAnimation.Buffer
calloc(int capacity)
Returns a newAIAnimation.Buffer
instance allocated withmemCalloc
.static AIAnimation
callocStack()
Returns a newAIAnimation
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static AIAnimation.Buffer
callocStack(int capacity)
Returns a newAIAnimation.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static AIAnimation.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static AIAnimation
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static AIAnimation
create()
Returns a newAIAnimation
instance allocated withBufferUtils
.static AIAnimation.Buffer
create(int capacity)
Returns a newAIAnimation.Buffer
instance allocated withBufferUtils
.static AIAnimation
create(long address)
Returns a newAIAnimation
instance for the specified memory address.static AIAnimation.Buffer
create(long address, int capacity)
Create aAIAnimation.Buffer
instance at the specified memory.static AIAnimation
createSafe(long address)
static AIAnimation.Buffer
createSafe(long address, int capacity)
static AIAnimation
malloc()
Returns a newAIAnimation
instance allocated withmemAlloc
.static AIAnimation.Buffer
malloc(int capacity)
Returns a newAIAnimation.Buffer
instance allocated withmemAlloc
.static AIAnimation
mallocStack()
Returns a newAIAnimation
instance allocated on the thread-localMemoryStack
.static AIAnimation.Buffer
mallocStack(int capacity)
Returns a newAIAnimation.Buffer
instance allocated on the thread-localMemoryStack
.static AIAnimation.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation.Buffer
instance allocated on the specifiedMemoryStack
.static AIAnimation
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
.org.lwjgl.PointerBuffer
mChannels()
Returns aPointerBuffer
view of the data pointed to by themChannels
field.AIAnimation
mChannels(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themChannels
field.double
mDuration()
Returns the value of themDuration
field.AIAnimation
mDuration(double value)
Sets the specified value to themDuration
field.org.lwjgl.PointerBuffer
mMeshChannels()
Returns aPointerBuffer
view of the data pointed to by themMeshChannels
field.AIAnimation
mMeshChannels(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themMeshChannels
field.org.lwjgl.PointerBuffer
mMorphMeshChannels()
Returns aPointerBuffer
view of the data pointed to by themMorphMeshChannels
field.AIAnimation
mMorphMeshChannels(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themMorphMeshChannels
field.AIString
mName()
Returns aAIString
view of themName
field.AIAnimation
mName(java.util.function.Consumer<AIString> consumer)
Passes themName
field to the specifiedConsumer
.AIAnimation
mName(AIString value)
Copies the specifiedAIString
to themName
field.int
mNumChannels()
Returns the value of themNumChannels
field.int
mNumMeshChannels()
Returns the value of themNumMeshChannels
field.int
mNumMorphMeshChannels()
Returns the value of themNumMorphMeshChannels
field.double
mTicksPerSecond()
Returns the value of themTicksPerSecond
field.AIAnimation
mTicksPerSecond(double value)
Sets the specified value to themTicksPerSecond
field.static org.lwjgl.PointerBuffer
nmChannels(long struct)
Unsafe version ofmChannels
.static void
nmChannels(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmChannels
.static double
nmDuration(long struct)
Unsafe version ofmDuration()
.static void
nmDuration(long struct, double value)
Unsafe version ofmDuration
.static org.lwjgl.PointerBuffer
nmMeshChannels(long struct)
Unsafe version ofmMeshChannels
.static void
nmMeshChannels(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmMeshChannels
.static org.lwjgl.PointerBuffer
nmMorphMeshChannels(long struct)
Unsafe version ofmMorphMeshChannels
.static void
nmMorphMeshChannels(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmMorphMeshChannels
.static AIString
nmName(long struct)
Unsafe version ofmName()
.static void
nmName(long struct, AIString value)
Unsafe version ofmName
.static int
nmNumChannels(long struct)
Unsafe version ofmNumChannels()
.static void
nmNumChannels(long struct, int value)
Sets the specified value to themNumChannels
field of the specifiedstruct
.static int
nmNumMeshChannels(long struct)
Unsafe version ofmNumMeshChannels()
.static void
nmNumMeshChannels(long struct, int value)
Sets the specified value to themNumMeshChannels
field of the specifiedstruct
.static int
nmNumMorphMeshChannels(long struct)
Unsafe version ofmNumMorphMeshChannels()
.static void
nmNumMorphMeshChannels(long struct, int value)
Sets the specified value to themNumMorphMeshChannels
field of the specifiedstruct
.static double
nmTicksPerSecond(long struct)
Unsafe version ofmTicksPerSecond()
.static void
nmTicksPerSecond(long struct, double value)
Unsafe version ofmTicksPerSecond
.AIAnimation
set(AIAnimation src)
Copies the specified struct data to this struct.AIAnimation
set(AIString mName, double mDuration, double mTicksPerSecond, org.lwjgl.PointerBuffer mChannels, org.lwjgl.PointerBuffer mMeshChannels, org.lwjgl.PointerBuffer mMorphMeshChannels)
Initializes this struct with the specified values.int
sizeof()
static void
validate(long struct)
Validates pointer members that should not beNULL
.static void
validate(long array, int count)
Callsvalidate(long)
for each struct contained in the specified struct array.
-
-
-
Constructor Detail
-
AIAnimation
public AIAnimation(java.nio.ByteBuffer container)
Creates aAIAnimation
instance at the current position of the specifiedByteBuffer
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 Detail
-
sizeof
public int sizeof()
- Specified by:
sizeof
in classorg.lwjgl.system.Struct
-
mDuration
public double mDuration()
Returns the value of themDuration
field.
-
mTicksPerSecond
public double mTicksPerSecond()
Returns the value of themTicksPerSecond
field.
-
mNumChannels
public int mNumChannels()
Returns the value of themNumChannels
field.
-
mChannels
@Nullable public org.lwjgl.PointerBuffer mChannels()
Returns aPointerBuffer
view of the data pointed to by themChannels
field.
-
mNumMeshChannels
public int mNumMeshChannels()
Returns the value of themNumMeshChannels
field.
-
mMeshChannels
@Nullable public org.lwjgl.PointerBuffer mMeshChannels()
Returns aPointerBuffer
view of the data pointed to by themMeshChannels
field.
-
mNumMorphMeshChannels
public int mNumMorphMeshChannels()
Returns the value of themNumMorphMeshChannels
field.
-
mMorphMeshChannels
@Nullable public org.lwjgl.PointerBuffer mMorphMeshChannels()
Returns aPointerBuffer
view of the data pointed to by themMorphMeshChannels
field.
-
mName
public AIAnimation mName(AIString value)
Copies the specifiedAIString
to themName
field.
-
mName
public AIAnimation mName(java.util.function.Consumer<AIString> consumer)
Passes themName
field to the specifiedConsumer
.
-
mDuration
public AIAnimation mDuration(double value)
Sets the specified value to themDuration
field.
-
mTicksPerSecond
public AIAnimation mTicksPerSecond(double value)
Sets the specified value to themTicksPerSecond
field.
-
mChannels
public AIAnimation mChannels(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themChannels
field.
-
mMeshChannels
public AIAnimation mMeshChannels(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themMeshChannels
field.
-
mMorphMeshChannels
public AIAnimation mMorphMeshChannels(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themMorphMeshChannels
field.
-
set
public AIAnimation set(AIString mName, double mDuration, double mTicksPerSecond, @Nullable org.lwjgl.PointerBuffer mChannels, @Nullable org.lwjgl.PointerBuffer mMeshChannels, @Nullable org.lwjgl.PointerBuffer mMorphMeshChannels)
Initializes this struct with the specified values.
-
set
public AIAnimation set(AIAnimation src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static AIAnimation malloc()
Returns a newAIAnimation
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static AIAnimation calloc()
Returns a newAIAnimation
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static AIAnimation create()
Returns a newAIAnimation
instance allocated withBufferUtils
.
-
create
public static AIAnimation create(long address)
Returns a newAIAnimation
instance for the specified memory address.
-
createSafe
@Nullable public static AIAnimation createSafe(long address)
-
malloc
public static AIAnimation.Buffer malloc(int capacity)
Returns a newAIAnimation.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static AIAnimation.Buffer calloc(int capacity)
Returns a newAIAnimation.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static AIAnimation.Buffer create(int capacity)
Returns a newAIAnimation.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static AIAnimation.Buffer create(long address, int capacity)
Create aAIAnimation.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static AIAnimation.Buffer createSafe(long address, int capacity)
-
mallocStack
public static AIAnimation mallocStack()
Returns a newAIAnimation
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static AIAnimation callocStack()
Returns a newAIAnimation
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static AIAnimation mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static AIAnimation callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static AIAnimation.Buffer mallocStack(int capacity)
Returns a newAIAnimation.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static AIAnimation.Buffer callocStack(int capacity)
Returns a newAIAnimation.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static AIAnimation.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static AIAnimation.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nmDuration
public static double nmDuration(long struct)
Unsafe version ofmDuration()
.
-
nmTicksPerSecond
public static double nmTicksPerSecond(long struct)
Unsafe version ofmTicksPerSecond()
.
-
nmNumChannels
public static int nmNumChannels(long struct)
Unsafe version ofmNumChannels()
.
-
nmChannels
@Nullable public static org.lwjgl.PointerBuffer nmChannels(long struct)
Unsafe version ofmChannels
.
-
nmNumMeshChannels
public static int nmNumMeshChannels(long struct)
Unsafe version ofmNumMeshChannels()
.
-
nmMeshChannels
@Nullable public static org.lwjgl.PointerBuffer nmMeshChannels(long struct)
Unsafe version ofmMeshChannels
.
-
nmNumMorphMeshChannels
public static int nmNumMorphMeshChannels(long struct)
Unsafe version ofmNumMorphMeshChannels()
.
-
nmMorphMeshChannels
@Nullable public static org.lwjgl.PointerBuffer nmMorphMeshChannels(long struct)
Unsafe version ofmMorphMeshChannels
.
-
nmDuration
public static void nmDuration(long struct, double value)
Unsafe version ofmDuration
.
-
nmTicksPerSecond
public static void nmTicksPerSecond(long struct, double value)
Unsafe version ofmTicksPerSecond
.
-
nmNumChannels
public static void nmNumChannels(long struct, int value)
Sets the specified value to themNumChannels
field of the specifiedstruct
.
-
nmChannels
public static void nmChannels(long struct, @Nullable org.lwjgl.PointerBuffer value)
Unsafe version ofmChannels
.
-
nmNumMeshChannels
public static void nmNumMeshChannels(long struct, int value)
Sets the specified value to themNumMeshChannels
field of the specifiedstruct
.
-
nmMeshChannels
public static void nmMeshChannels(long struct, @Nullable org.lwjgl.PointerBuffer value)
Unsafe version ofmMeshChannels
.
-
nmNumMorphMeshChannels
public static void nmNumMorphMeshChannels(long struct, int value)
Sets the specified value to themNumMorphMeshChannels
field of the specifiedstruct
.
-
nmMorphMeshChannels
public static void nmMorphMeshChannels(long struct, @Nullable org.lwjgl.PointerBuffer value)
Unsafe version ofmMorphMeshChannels
.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-
validate
public static void validate(long array, int count)
Callsvalidate(long)
for each struct contained in the specified struct array.- Parameters:
array
- the struct array to validatecount
- the number of structs inarray
-
-