Package org.lwjgl.assimp
Class AIColor4D
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.assimp.AIColor4D
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class AIColor4D extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceRepresents a color in Red-Green-Blue space including an alpha component. Color values range from 0 to 1.Member documentation
r– The red color componentg– The green color componentb– The blue color componenta– The alpha color component
Layout
struct aiColor4D { float r; float g; float b; float a; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAIColor4D.BufferAn array ofAIColor4Dstructs.
-
Constructor Summary
Constructors Constructor Description AIColor4D(java.nio.ByteBuffer container)Creates aAIColor4Dinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description floata()Returns the value of theafield.AIColor4Da(float value)Sets the specified value to theafield.floatb()Returns the value of thebfield.AIColor4Db(float value)Sets the specified value to thebfield.static AIColor4Dcalloc()Returns a newAIColor4Dinstance allocated withmemCalloc.static AIColor4D.Buffercalloc(int capacity)Returns a newAIColor4D.Bufferinstance allocated withmemCalloc.static AIColor4DcallocStack()Returns a newAIColor4Dinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static AIColor4D.BuffercallocStack(int capacity)Returns a newAIColor4D.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static AIColor4D.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIColor4D.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIColor4DcallocStack(org.lwjgl.system.MemoryStack stack)Returns a newAIColor4Dinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIColor4Dcreate()Returns a newAIColor4Dinstance allocated withBufferUtils.static AIColor4D.Buffercreate(int capacity)Returns a newAIColor4D.Bufferinstance allocated withBufferUtils.static AIColor4Dcreate(long address)Returns a newAIColor4Dinstance for the specified memory address.static AIColor4D.Buffercreate(long address, int capacity)Create aAIColor4D.Bufferinstance at the specified memory.static AIColor4DcreateSafe(long address)static AIColor4D.BuffercreateSafe(long address, int capacity)floatg()Returns the value of thegfield.AIColor4Dg(float value)Sets the specified value to thegfield.static AIColor4Dmalloc()Returns a newAIColor4Dinstance allocated withmemAlloc.static AIColor4D.Buffermalloc(int capacity)Returns a newAIColor4D.Bufferinstance allocated withmemAlloc.static AIColor4DmallocStack()Returns a newAIColor4Dinstance allocated on the thread-localMemoryStack.static AIColor4D.BuffermallocStack(int capacity)Returns a newAIColor4D.Bufferinstance allocated on the thread-localMemoryStack.static AIColor4D.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIColor4D.Bufferinstance allocated on the specifiedMemoryStack.static AIColor4DmallocStack(org.lwjgl.system.MemoryStack stack)Returns a newAIColor4Dinstance allocated on the specifiedMemoryStack.static floatna(long struct)Unsafe version ofa().static voidna(long struct, float value)Unsafe version ofa.static floatnb(long struct)Unsafe version ofb().static voidnb(long struct, float value)Unsafe version ofb.static floatng(long struct)Unsafe version ofg().static voidng(long struct, float value)Unsafe version ofg.static floatnr(long struct)Unsafe version ofr().static voidnr(long struct, float value)Unsafe version ofr.floatr()Returns the value of therfield.AIColor4Dr(float value)Sets the specified value to therfield.AIColor4Dset(float r, float g, float b, float a)Initializes this struct with the specified values.AIColor4Dset(AIColor4D src)Copies the specified struct data to this struct.intsizeof()
-
-
-
Constructor Detail
-
AIColor4D
public AIColor4D(java.nio.ByteBuffer container)
Creates aAIColor4Dinstance at the current position of the specifiedByteBuffercontainer. 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:
sizeofin classorg.lwjgl.system.Struct
-
r
public float r()
Returns the value of therfield.
-
g
public float g()
Returns the value of thegfield.
-
b
public float b()
Returns the value of thebfield.
-
a
public float a()
Returns the value of theafield.
-
r
public AIColor4D r(float value)
Sets the specified value to therfield.
-
g
public AIColor4D g(float value)
Sets the specified value to thegfield.
-
b
public AIColor4D b(float value)
Sets the specified value to thebfield.
-
a
public AIColor4D a(float value)
Sets the specified value to theafield.
-
set
public AIColor4D set(float r, float g, float b, float a)
Initializes this struct with the specified values.
-
set
public AIColor4D set(AIColor4D src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static AIColor4D malloc()
Returns a newAIColor4Dinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static AIColor4D calloc()
Returns a newAIColor4Dinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static AIColor4D create()
Returns a newAIColor4Dinstance allocated withBufferUtils.
-
create
public static AIColor4D create(long address)
Returns a newAIColor4Dinstance for the specified memory address.
-
createSafe
@Nullable public static AIColor4D createSafe(long address)
-
malloc
public static AIColor4D.Buffer malloc(int capacity)
Returns a newAIColor4D.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static AIColor4D.Buffer calloc(int capacity)
Returns a newAIColor4D.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static AIColor4D.Buffer create(int capacity)
Returns a newAIColor4D.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static AIColor4D.Buffer create(long address, int capacity)
Create aAIColor4D.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static AIColor4D.Buffer createSafe(long address, int capacity)
-
mallocStack
public static AIColor4D mallocStack()
Returns a newAIColor4Dinstance allocated on the thread-localMemoryStack.
-
callocStack
public static AIColor4D callocStack()
Returns a newAIColor4Dinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static AIColor4D mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAIColor4Dinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static AIColor4D callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAIColor4Dinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static AIColor4D.Buffer mallocStack(int capacity)
Returns a newAIColor4D.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static AIColor4D.Buffer callocStack(int capacity)
Returns a newAIColor4D.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static AIColor4D.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIColor4D.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static AIColor4D.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIColor4D.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nr
public static float nr(long struct)
Unsafe version ofr().
-
ng
public static float ng(long struct)
Unsafe version ofg().
-
nb
public static float nb(long struct)
Unsafe version ofb().
-
na
public static float na(long struct)
Unsafe version ofa().
-
nr
public static void nr(long struct, float value)Unsafe version ofr.
-
ng
public static void ng(long struct, float value)Unsafe version ofg.
-
nb
public static void nb(long struct, float value)Unsafe version ofb.
-
na
public static void na(long struct, float value)Unsafe version ofa.
-
-