Package org.lwjgl.assimp
Class AIExportDataBlob
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.assimp.AIExportDataBlob
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class AIExportDataBlob extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceDescribes a blob of exported scene data. UseExportSceneToBlobto create a blob containing an exported scene. The memory referred by this structure is owned by Assimp. to free its resources. Don't try to free the memory on your side - it will crash for most build configurations due to conflicting heaps.Blobs can be nested - each blob may reference another blob, which may in turn reference another blob and so on. This is used when exporters write more than one output file for a given
AIScene. See the remarks foraiExportDataBlob::namefor more information.Layout
struct aiExportDataBlob { size_tsize(); void *data();struct aiStringname();struct aiExportDataBlob*next(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAIExportDataBlob.BufferAn array ofAIExportDataBlobstructs.
-
Constructor Summary
Constructors Constructor Description AIExportDataBlob(java.nio.ByteBuffer container)Creates aAIExportDataBlobinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static AIExportDataBlobcalloc()Returns a newAIExportDataBlobinstance allocated withmemCalloc.static AIExportDataBlob.Buffercalloc(int capacity)Returns a newAIExportDataBlob.Bufferinstance allocated withmemCalloc.static AIExportDataBlob.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIExportDataBlob.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIExportDataBlobcalloc(org.lwjgl.system.MemoryStack stack)Returns a newAIExportDataBlobinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIExportDataBlobcallocStack()Deprecated.static AIExportDataBlob.BuffercallocStack(int capacity)Deprecated.static AIExportDataBlob.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static AIExportDataBlobcallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static AIExportDataBlobcreate()Returns a newAIExportDataBlobinstance allocated withBufferUtils.static AIExportDataBlob.Buffercreate(int capacity)Returns a newAIExportDataBlob.Bufferinstance allocated withBufferUtils.static AIExportDataBlobcreate(long address)Returns a newAIExportDataBlobinstance for the specified memory address.static AIExportDataBlob.Buffercreate(long address, int capacity)Create aAIExportDataBlob.Bufferinstance at the specified memory.static AIExportDataBlobcreateSafe(long address)static AIExportDataBlob.BuffercreateSafe(long address, int capacity)java.nio.ByteBufferdata()The data.AIExportDataBlobdata(java.nio.ByteBuffer value)Sets the address of the specifiedByteBufferto thedata()field.static AIExportDataBlobmalloc()Returns a newAIExportDataBlobinstance allocated withmemAlloc.static AIExportDataBlob.Buffermalloc(int capacity)Returns a newAIExportDataBlob.Bufferinstance allocated withmemAlloc.static AIExportDataBlob.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIExportDataBlob.Bufferinstance allocated on the specifiedMemoryStack.static AIExportDataBlobmalloc(org.lwjgl.system.MemoryStack stack)Returns a newAIExportDataBlobinstance allocated on the specifiedMemoryStack.static AIExportDataBlobmallocStack()Deprecated.static AIExportDataBlob.BuffermallocStack(int capacity)Deprecated.static AIExportDataBlob.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static AIExportDataBlobmallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.AIStringname()Name of the blob.AIExportDataBlobname(java.util.function.Consumer<AIString> consumer)Passes thename()field to the specifiedConsumer.AIExportDataBlobname(AIString value)static java.nio.ByteBufferndata(long struct)Unsafe version ofdata.static voidndata(long struct, java.nio.ByteBuffer value)Unsafe version ofdata.AIExportDataBlobnext()Pointer to the next blob in the chain or NULL if there is none.AIExportDataBlobnext(AIExportDataBlob value)Sets the address of the specifiedAIExportDataBlobto thenext()field.static AIStringnname(long struct)Unsafe version ofname().static voidnname(long struct, AIString value)Unsafe version ofname.static AIExportDataBlobnnext(long struct)Unsafe version ofnext().static voidnnext(long struct, AIExportDataBlob value)Unsafe version ofnext.static longnsize(long struct)Unsafe version ofsize().static voidnsize(long struct, long value)Sets the specified value to thesizefield of the specifiedstruct.AIExportDataBlobset(java.nio.ByteBuffer data, AIString name, AIExportDataBlob next)Initializes this struct with the specified values.AIExportDataBlobset(AIExportDataBlob src)Copies the specified struct data to this struct.longsize()Size of the data in bytesintsizeof()static voidvalidate(long struct)Validates pointer members that should not beNULL.
-
-
-
Constructor Detail
-
AIExportDataBlob
public AIExportDataBlob(java.nio.ByteBuffer container)
Creates aAIExportDataBlobinstance 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
-
size
public long size()
Size of the data in bytes
-
data
public java.nio.ByteBuffer data()
The data.
-
name
public AIString name()
Name of the blob. An empty string always indicates the first (and primary) blob, which contains the actual file data. Any other blobs are auxiliary files produced by exporters (i.e. material files). Existence of such files depends on the file format. Most formats don't split assets across multiple files.If used, blob names usually contain the file extension that should be used when writing the data to disc.
The blob names generated can be influenced by setting the
Assimp.AI_CONFIG_EXPORT_BLOB_NAMEexport property to the name that is used for the master blob. All other names are typically derived from the base name, by the file format exporter.
-
next
@Nullable public AIExportDataBlob next()
Pointer to the next blob in the chain or NULL if there is none.
-
data
public AIExportDataBlob data(java.nio.ByteBuffer value)
Sets the address of the specifiedByteBufferto thedata()field.
-
name
public AIExportDataBlob name(AIString value)
-
name
public AIExportDataBlob name(java.util.function.Consumer<AIString> consumer)
Passes thename()field to the specifiedConsumer.
-
next
public AIExportDataBlob next(@Nullable AIExportDataBlob value)
Sets the address of the specifiedAIExportDataBlobto thenext()field.
-
set
public AIExportDataBlob set(java.nio.ByteBuffer data, AIString name, @Nullable AIExportDataBlob next)
Initializes this struct with the specified values.
-
set
public AIExportDataBlob set(AIExportDataBlob src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static AIExportDataBlob malloc()
Returns a newAIExportDataBlobinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static AIExportDataBlob calloc()
Returns a newAIExportDataBlobinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static AIExportDataBlob create()
Returns a newAIExportDataBlobinstance allocated withBufferUtils.
-
create
public static AIExportDataBlob create(long address)
Returns a newAIExportDataBlobinstance for the specified memory address.
-
createSafe
@Nullable public static AIExportDataBlob createSafe(long address)
-
malloc
public static AIExportDataBlob.Buffer malloc(int capacity)
Returns a newAIExportDataBlob.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static AIExportDataBlob.Buffer calloc(int capacity)
Returns a newAIExportDataBlob.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static AIExportDataBlob.Buffer create(int capacity)
Returns a newAIExportDataBlob.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static AIExportDataBlob.Buffer create(long address, int capacity)
Create aAIExportDataBlob.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static AIExportDataBlob.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static AIExportDataBlob mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static AIExportDataBlob callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static AIExportDataBlob mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static AIExportDataBlob callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static AIExportDataBlob.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static AIExportDataBlob.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static AIExportDataBlob.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 AIExportDataBlob.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static AIExportDataBlob malloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIExportDataBlobinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static AIExportDataBlob calloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIExportDataBlobinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static AIExportDataBlob.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIExportDataBlob.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static AIExportDataBlob.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIExportDataBlob.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nsize
public static long nsize(long struct)
Unsafe version ofsize().
-
ndata
public static java.nio.ByteBuffer ndata(long struct)
Unsafe version ofdata.
-
nnext
@Nullable public static AIExportDataBlob nnext(long struct)
Unsafe version ofnext().
-
nsize
public static void nsize(long struct, long value)Sets the specified value to thesizefield of the specifiedstruct.
-
ndata
public static void ndata(long struct, java.nio.ByteBuffer value)Unsafe version ofdata.
-
nnext
public static void nnext(long struct, @Nullable AIExportDataBlob value)Unsafe version ofnext.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-
-