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.Layout
struct aiAnimation {
struct aiString
mName()
; doublemDuration()
; doublemTicksPerSecond()
; unsigned intmNumChannels()
;struct aiNodeAnim
**mChannels()
; unsigned intmNumMeshChannels()
;struct aiMeshAnim
**mMeshChannels()
; unsigned intmNumMorphMeshChannels()
;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 Deprecated 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.Buffer
calloc(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
calloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static AIAnimation
callocStack()
Deprecated.static AIAnimation.Buffer
callocStack(int capacity)
Deprecated.static AIAnimation.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.static AIAnimation
callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.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.Buffer
malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation.Buffer
instance allocated on the specifiedMemoryStack
.static AIAnimation
malloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
.static AIAnimation
mallocStack()
Deprecated.static AIAnimation.Buffer
mallocStack(int capacity)
Deprecated.static AIAnimation.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.static AIAnimation
mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.org.lwjgl.PointerBuffer
mChannels()
The node animation channels.AIAnimation
mChannels(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themChannels()
field.double
mDuration()
Duration of the animation in ticks.AIAnimation
mDuration(double value)
Sets the specified value to themDuration()
field.org.lwjgl.PointerBuffer
mMeshChannels()
The mesh animation channels.AIAnimation
mMeshChannels(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themMeshChannels()
field.org.lwjgl.PointerBuffer
mMorphMeshChannels()
the morph mesh animation channels.AIAnimation
mMorphMeshChannels(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themMorphMeshChannels()
field.AIString
mName()
The name of the animation.AIAnimation
mName(java.util.function.Consumer<AIString> consumer)
Passes themName()
field to the specifiedConsumer
.AIAnimation
mName(AIString value)
int
mNumChannels()
The number of bone animation channels.int
mNumMeshChannels()
The number of mesh animation channels.int
mNumMorphMeshChannels()
the number of mesh animation channels.double
mTicksPerSecond()
Ticks per second.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
.
-
-
-
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
-
mName
public AIString 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
public double mDuration()
Duration of the animation in ticks.
-
mTicksPerSecond
public double mTicksPerSecond()
Ticks per second. 0 if not specified in the imported file
-
mNumChannels
public int mNumChannels()
The number of bone animation channels. Each channel affects a single node.
-
mChannels
@Nullable public org.lwjgl.PointerBuffer mChannels()
The node animation channels. Each channel affects a single node. The array ismNumChannels
in size.
-
mNumMeshChannels
public int mNumMeshChannels()
The number of mesh animation channels. Each channel affects a single mesh and defines vertex-based animation.
-
mMeshChannels
@Nullable public org.lwjgl.PointerBuffer mMeshChannels()
The mesh animation channels. Each channel affects a single mesh. The array ismNumMeshChannels
in size.
-
mNumMorphMeshChannels
public int mNumMorphMeshChannels()
the number of mesh animation channels. Each channel affects a single mesh and defines morphing animation.
-
mMorphMeshChannels
@Nullable public org.lwjgl.PointerBuffer mMorphMeshChannels()
the morph mesh animation channels. Each channel affects a single mesh. The array ismNumMorphMeshChannels
in size.
-
mName
public AIAnimation mName(AIString value)
-
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
@Deprecated public static AIAnimation mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead.
-
callocStack
@Deprecated public static AIAnimation callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead.
-
mallocStack
@Deprecated public static AIAnimation mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead.
-
callocStack
@Deprecated public static AIAnimation callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead.
-
mallocStack
@Deprecated public static AIAnimation.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead.
-
callocStack
@Deprecated public static AIAnimation.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead.
-
mallocStack
@Deprecated public static AIAnimation.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead.
-
callocStack
@Deprecated public static AIAnimation.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead.
-
malloc
public static AIAnimation malloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIAnimation
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
public static AIAnimation calloc(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
-
malloc
public static AIAnimation.Buffer malloc(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
-
calloc
public static AIAnimation.Buffer calloc(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
-
-