Package org.lwjgl.assimp
Class AIScene
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.assimp.AIScene
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class AIScene extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceThe root structure of the imported data.Everything that was imported from the given file can be accessed from here. Objects of this class are generally maintained and owned by Assimp, not by the caller. You shouldn't want to instance it, nor should you ever try to delete a given scene on your own.
Layout
struct aiScene { unsigned intmFlags();struct aiNode*mRootNode(); unsigned intmNumMeshes();struct aiMesh**mMeshes(); unsigned intmNumMaterials();struct aiMaterial**mMaterials(); unsigned intmNumAnimations();struct aiAnimation**mAnimations(); unsigned intmNumTextures();struct aiTexture**mTextures(); unsigned intmNumLights();struct aiLight**mLights(); unsigned intmNumCameras();struct aiCamera**mCameras();struct aiMetadata*mMetaData();struct aiStringmName(); char * mPrivate; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classAIScene.BufferAn array ofAIScenestructs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intMANIMATIONS
MCAMERAS
MFLAGS
MLIGHTS
MMATERIALS
MMESHES
MMETADATA
MNAME
MNUMANIMATIONS
MNUMCAMERAS
MNUMLIGHTS
MNUMMATERIALS
MNUMMESHES
MNUMTEXTURES
MPRIVATE
MROOTNODE
MTEXTURESThe struct member offsets.static intSIZEOFThe struct size in bytes.
-
Constructor Summary
Constructors Constructor Description AIScene(java.nio.ByteBuffer container)Creates aAISceneinstance 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 AIScenecalloc()Returns a newAISceneinstance allocated withmemCalloc.static AIScene.Buffercalloc(int capacity)Returns a newAIScene.Bufferinstance allocated withmemCalloc.static AIScene.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIScene.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIScenecalloc(org.lwjgl.system.MemoryStack stack)Returns a newAISceneinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIScenecallocStack()Deprecated.static AIScene.BuffercallocStack(int capacity)Deprecated.static AIScene.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static AIScenecallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.static AIScenecreate()Returns a newAISceneinstance allocated withBufferUtils.static AIScene.Buffercreate(int capacity)Returns a newAIScene.Bufferinstance allocated withBufferUtils.static AIScenecreate(long address)Returns a newAISceneinstance for the specified memory address.static AIScene.Buffercreate(long address, int capacity)Create aAIScene.Bufferinstance at the specified memory.static AIScenecreateSafe(long address)static AIScene.BuffercreateSafe(long address, int capacity)static AIScenemalloc()Returns a newAISceneinstance allocated withmemAlloc.static AIScene.Buffermalloc(int capacity)Returns a newAIScene.Bufferinstance allocated withmemAlloc.static AIScene.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIScene.Bufferinstance allocated on the specifiedMemoryStack.static AIScenemalloc(org.lwjgl.system.MemoryStack stack)Returns a newAISceneinstance allocated on the specifiedMemoryStack.static AIScenemallocStack()Deprecated.static AIScene.BuffermallocStack(int capacity)Deprecated.static AIScene.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Deprecated.static AIScenemallocStack(org.lwjgl.system.MemoryStack stack)Deprecated.org.lwjgl.PointerBuffermAnimations()The array of animations.AIScenemAnimations(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themAnimations()field.org.lwjgl.PointerBuffermCameras()The array of cameras.AIScenemCameras(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themCameras()field.intmFlags()Any combination of the AI_SCENE_FLAGS_XXX flags.AIScenemFlags(int value)Sets the specified value to themFlags()field.org.lwjgl.PointerBuffermLights()The array of light sources.AIScenemLights(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themLights()field.org.lwjgl.PointerBuffermMaterials()The array of materials.AIScenemMaterials(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themMaterials()field.org.lwjgl.PointerBuffermMeshes()The array of meshes.AIScenemMeshes(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themMeshes()field.AIMetaDatamMetaData()The global metadata assigned to the scene itself.AIScenemMetaData(AIMetaData value)Sets the address of the specifiedAIMetaDatato themMetaData()field.AIStringmName()The name of the scene itself.AIScenemName(java.util.function.Consumer<AIString> consumer)Passes themName()field to the specifiedConsumer.AIScenemName(AIString value)intmNumAnimations()The number of animations in the scene.intmNumCameras()The number of cameras in the scene.intmNumLights()The number of light sources in the scene.intmNumMaterials()The number of materials in the scene.intmNumMeshes()The number of meshes in the scene.intmNumTextures()The number of textures embedded into the fileAINodemRootNode()The root node of the hierarchy.AIScenemRootNode(AINode value)Sets the address of the specifiedAINodeto themRootNode()field.org.lwjgl.PointerBuffermTextures()The array of embedded textures.AIScenemTextures(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themTextures()field.static org.lwjgl.PointerBuffernmAnimations(long struct)Unsafe version ofmAnimations.static voidnmAnimations(long struct, org.lwjgl.PointerBuffer value)Unsafe version ofmAnimations.static org.lwjgl.PointerBuffernmCameras(long struct)Unsafe version ofmCameras.static voidnmCameras(long struct, org.lwjgl.PointerBuffer value)Unsafe version ofmCameras.static intnmFlags(long struct)Unsafe version ofmFlags().static voidnmFlags(long struct, int value)Unsafe version ofmFlags.static org.lwjgl.PointerBuffernmLights(long struct)Unsafe version ofmLights.static voidnmLights(long struct, org.lwjgl.PointerBuffer value)Unsafe version ofmLights.static org.lwjgl.PointerBuffernmMaterials(long struct)Unsafe version ofmMaterials.static voidnmMaterials(long struct, org.lwjgl.PointerBuffer value)Unsafe version ofmMaterials.static org.lwjgl.PointerBuffernmMeshes(long struct)Unsafe version ofmMeshes.static voidnmMeshes(long struct, org.lwjgl.PointerBuffer value)Unsafe version ofmMeshes.static AIMetaDatanmMetaData(long struct)Unsafe version ofmMetaData().static voidnmMetaData(long struct, AIMetaData value)Unsafe version ofmMetaData.static AIStringnmName(long struct)Unsafe version ofmName().static voidnmName(long struct, AIString value)Unsafe version ofmName.static intnmNumAnimations(long struct)Unsafe version ofmNumAnimations().static voidnmNumAnimations(long struct, int value)Sets the specified value to themNumAnimationsfield of the specifiedstruct.static intnmNumCameras(long struct)Unsafe version ofmNumCameras().static voidnmNumCameras(long struct, int value)Sets the specified value to themNumCamerasfield of the specifiedstruct.static intnmNumLights(long struct)Unsafe version ofmNumLights().static voidnmNumLights(long struct, int value)Sets the specified value to themNumLightsfield of the specifiedstruct.static intnmNumMaterials(long struct)Unsafe version ofmNumMaterials().static voidnmNumMaterials(long struct, int value)Sets the specified value to themNumMaterialsfield of the specifiedstruct.static intnmNumMeshes(long struct)Unsafe version ofmNumMeshes().static voidnmNumMeshes(long struct, int value)Sets the specified value to themNumMeshesfield of the specifiedstruct.static intnmNumTextures(long struct)Unsafe version ofmNumTextures().static voidnmNumTextures(long struct, int value)Sets the specified value to themNumTexturesfield of the specifiedstruct.static java.nio.ByteBuffernmPrivate(long struct, int capacity)static voidnmPrivate(long struct, java.nio.ByteBuffer value)static AINodenmRootNode(long struct)Unsafe version ofmRootNode().static voidnmRootNode(long struct, AINode value)Unsafe version ofmRootNode.static org.lwjgl.PointerBuffernmTextures(long struct)Unsafe version ofmTextures.static voidnmTextures(long struct, org.lwjgl.PointerBuffer value)Unsafe version ofmTextures.AISceneset(int mFlags, AINode mRootNode, org.lwjgl.PointerBuffer mMeshes, org.lwjgl.PointerBuffer mMaterials, org.lwjgl.PointerBuffer mAnimations, org.lwjgl.PointerBuffer mTextures, org.lwjgl.PointerBuffer mLights, org.lwjgl.PointerBuffer mCameras, AIMetaData mMetaData, AIString mName)Initializes this struct with the specified values.AISceneset(AIScene src)Copies the specified struct data to this struct.intsizeof()static voidvalidate(long struct)Validates pointer members that should not beNULL.
-
-
-
Field Detail
-
SIZEOF
The struct size in bytes.
-
ALIGNOF
The struct alignment in bytes.
-
MFLAGS, MROOTNODE, MNUMMESHES, MMESHES, MNUMMATERIALS, MMATERIALS, MNUMANIMATIONS, MANIMATIONS, MNUMTEXTURES, MTEXTURES, MNUMLIGHTS, MLIGHTS, MNUMCAMERAS, MCAMERAS, MMETADATA, MNAME, MPRIVATE
The struct member offsets.
-
-
Constructor Detail
-
AIScene
public AIScene(java.nio.ByteBuffer container)
Creates aAISceneinstance 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
-
mFlags
public int mFlags()
Any combination of the AI_SCENE_FLAGS_XXX flags. By default this value is 0, no flags are set. Most applications will want to reject all scenes with the AI_SCENE_FLAGS_INCOMPLETE bit set. One or more of:Assimp.AI_SCENE_FLAGS_INCOMPLETEAssimp.AI_SCENE_FLAGS_VALIDATEDAssimp.AI_SCENE_FLAGS_VALIDATION_WARNINGAssimp.AI_SCENE_FLAGS_NON_VERBOSE_FORMATAssimp.AI_SCENE_FLAGS_TERRAIN
-
mRootNode
@Nullable public AINode mRootNode()
The root node of the hierarchy. There will always be at least the root node if the import was successful (and no special flags have been set). Presence of further nodes depends on the format and content of the imported file.
-
mNumMeshes
public int mNumMeshes()
The number of meshes in the scene.
-
mMeshes
@Nullable public org.lwjgl.PointerBuffer mMeshes()
The array of meshes. Use the indices given in theAINodestructure to access this array. The array ismNumMeshesin size. If theAssimp.AI_SCENE_FLAGS_INCOMPLETEflag is not set there will always be at least ONE material.
-
mNumMaterials
public int mNumMaterials()
The number of materials in the scene.
-
mMaterials
@Nullable public org.lwjgl.PointerBuffer mMaterials()
The array of materials. Use the index given in eachAIMeshstructure to access this array. The array ismNumMaterialsin size. If theAssimp.AI_SCENE_FLAGS_INCOMPLETEflag is not set there will always be at least ONE material.
-
mNumAnimations
public int mNumAnimations()
The number of animations in the scene.
-
mAnimations
@Nullable public org.lwjgl.PointerBuffer mAnimations()
The array of animations. All animations imported from the given file are listed here. The array ismNumAnimationsin size.
-
mNumTextures
public int mNumTextures()
The number of textures embedded into the file
-
mTextures
@Nullable public org.lwjgl.PointerBuffer mTextures()
The array of embedded textures. Not many file formats embed their textures into the file. An example is Quake's MDL format (which is also used by some GameStudio versions)
-
mNumLights
public int mNumLights()
The number of light sources in the scene. Light sources are fully optional, in most cases this attribute will be 0
-
mLights
@Nullable public org.lwjgl.PointerBuffer mLights()
The array of light sources. All light sources imported from the given file are listed here. The array ismNumLightsin size.
-
mNumCameras
public int mNumCameras()
The number of cameras in the scene. Cameras are fully optional, in most cases this attribute will be 0
-
mCameras
@Nullable public org.lwjgl.PointerBuffer mCameras()
The array of cameras. All cameras imported from the given file are listed here. The array ismNumCamerasin size. The first camera in the array (if existing) is the default camera view into the scene.
-
mMetaData
@Nullable public AIMetaData mMetaData()
The global metadata assigned to the scene itself.This data contains global metadata which belongs to the scene like unit-conversions, versions, vendors or other model-specific data. This can be used to store format-specific metadata as well.
-
mName
public AIString mName()
The name of the scene itself.
-
mRootNode
public AIScene mRootNode(@Nullable AINode value)
Sets the address of the specifiedAINodeto themRootNode()field.
-
mMeshes
public AIScene mMeshes(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themMeshes()field.
-
mMaterials
public AIScene mMaterials(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themMaterials()field.
-
mAnimations
public AIScene mAnimations(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themAnimations()field.
-
mTextures
public AIScene mTextures(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themTextures()field.
-
mLights
public AIScene mLights(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themLights()field.
-
mCameras
public AIScene mCameras(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themCameras()field.
-
mMetaData
public AIScene mMetaData(@Nullable AIMetaData value)
Sets the address of the specifiedAIMetaDatato themMetaData()field.
-
mName
public AIScene mName(java.util.function.Consumer<AIString> consumer)
Passes themName()field to the specifiedConsumer.
-
set
public AIScene set(int mFlags, @Nullable AINode mRootNode, @Nullable org.lwjgl.PointerBuffer mMeshes, @Nullable org.lwjgl.PointerBuffer mMaterials, @Nullable org.lwjgl.PointerBuffer mAnimations, @Nullable org.lwjgl.PointerBuffer mTextures, @Nullable org.lwjgl.PointerBuffer mLights, @Nullable org.lwjgl.PointerBuffer mCameras, @Nullable AIMetaData mMetaData, AIString mName)
Initializes this struct with the specified values.
-
set
public AIScene set(AIScene src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static AIScene malloc()
Returns a newAISceneinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static AIScene calloc()
Returns a newAISceneinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static AIScene create()
Returns a newAISceneinstance allocated withBufferUtils.
-
create
public static AIScene create(long address)
Returns a newAISceneinstance for the specified memory address.
-
createSafe
@Nullable public static AIScene createSafe(long address)
-
malloc
public static AIScene.Buffer malloc(int capacity)
Returns a newAIScene.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static AIScene.Buffer calloc(int capacity)
Returns a newAIScene.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static AIScene.Buffer create(int capacity)
Returns a newAIScene.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static AIScene.Buffer create(long address, int capacity)
Create aAIScene.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static AIScene.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static AIScene mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static AIScene callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static AIScene mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)instead.
-
callocStack
@Deprecated public static AIScene callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)instead.
-
mallocStack
@Deprecated public static AIScene.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)instead.
-
callocStack
@Deprecated public static AIScene.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
mallocStack
@Deprecated public static AIScene.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 AIScene.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)instead.
-
malloc
public static AIScene malloc(org.lwjgl.system.MemoryStack stack)
Returns a newAISceneinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static AIScene calloc(org.lwjgl.system.MemoryStack stack)
Returns a newAISceneinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static AIScene.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIScene.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static AIScene.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIScene.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nmFlags
public static int nmFlags(long struct)
Unsafe version ofmFlags().
-
nmRootNode
@Nullable public static AINode nmRootNode(long struct)
Unsafe version ofmRootNode().
-
nmNumMeshes
public static int nmNumMeshes(long struct)
Unsafe version ofmNumMeshes().
-
nmMeshes
@Nullable public static org.lwjgl.PointerBuffer nmMeshes(long struct)
Unsafe version ofmMeshes.
-
nmNumMaterials
public static int nmNumMaterials(long struct)
Unsafe version ofmNumMaterials().
-
nmMaterials
@Nullable public static org.lwjgl.PointerBuffer nmMaterials(long struct)
Unsafe version ofmMaterials.
-
nmNumAnimations
public static int nmNumAnimations(long struct)
Unsafe version ofmNumAnimations().
-
nmAnimations
@Nullable public static org.lwjgl.PointerBuffer nmAnimations(long struct)
Unsafe version ofmAnimations.
-
nmNumTextures
public static int nmNumTextures(long struct)
Unsafe version ofmNumTextures().
-
nmTextures
@Nullable public static org.lwjgl.PointerBuffer nmTextures(long struct)
Unsafe version ofmTextures.
-
nmNumLights
public static int nmNumLights(long struct)
Unsafe version ofmNumLights().
-
nmLights
@Nullable public static org.lwjgl.PointerBuffer nmLights(long struct)
Unsafe version ofmLights.
-
nmNumCameras
public static int nmNumCameras(long struct)
Unsafe version ofmNumCameras().
-
nmCameras
@Nullable public static org.lwjgl.PointerBuffer nmCameras(long struct)
Unsafe version ofmCameras.
-
nmMetaData
@Nullable public static AIMetaData nmMetaData(long struct)
Unsafe version ofmMetaData().
-
nmPrivate
public static java.nio.ByteBuffer nmPrivate(long struct, int capacity)
-
nmFlags
public static void nmFlags(long struct, int value)Unsafe version ofmFlags.
-
nmRootNode
public static void nmRootNode(long struct, @Nullable AINode value)Unsafe version ofmRootNode.
-
nmNumMeshes
public static void nmNumMeshes(long struct, int value)Sets the specified value to themNumMeshesfield of the specifiedstruct.
-
nmMeshes
public static void nmMeshes(long struct, @Nullable org.lwjgl.PointerBuffer value)Unsafe version ofmMeshes.
-
nmNumMaterials
public static void nmNumMaterials(long struct, int value)Sets the specified value to themNumMaterialsfield of the specifiedstruct.
-
nmMaterials
public static void nmMaterials(long struct, @Nullable org.lwjgl.PointerBuffer value)Unsafe version ofmMaterials.
-
nmNumAnimations
public static void nmNumAnimations(long struct, int value)Sets the specified value to themNumAnimationsfield of the specifiedstruct.
-
nmAnimations
public static void nmAnimations(long struct, @Nullable org.lwjgl.PointerBuffer value)Unsafe version ofmAnimations.
-
nmNumTextures
public static void nmNumTextures(long struct, int value)Sets the specified value to themNumTexturesfield of the specifiedstruct.
-
nmTextures
public static void nmTextures(long struct, @Nullable org.lwjgl.PointerBuffer value)Unsafe version ofmTextures.
-
nmNumLights
public static void nmNumLights(long struct, int value)Sets the specified value to themNumLightsfield of the specifiedstruct.
-
nmLights
public static void nmLights(long struct, @Nullable org.lwjgl.PointerBuffer value)Unsafe version ofmLights.
-
nmNumCameras
public static void nmNumCameras(long struct, int value)Sets the specified value to themNumCamerasfield of the specifiedstruct.
-
nmCameras
public static void nmCameras(long struct, @Nullable org.lwjgl.PointerBuffer value)Unsafe version ofmCameras.
-
nmMetaData
public static void nmMetaData(long struct, @Nullable AIMetaData value)Unsafe version ofmMetaData.
-
nmPrivate
public static void nmPrivate(long struct, java.nio.ByteBuffer value)
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL.- Parameters:
struct- the struct to validate
-
-