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.
Member documentation
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_TERRAINmRootNode– 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– The number of meshes in the scene.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– The number of materials in the scene.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– The number of animations in the scene.mAnimations– The array of animations. All animations imported from the given file are listed here. The array ismNumAnimationsin size.mNumTextures– The number of textures embedded into the filemTextures– 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– The number of light sources in the scene. Light sources are fully optional, in most cases this attribute will be 0mLights– The array of light sources. All light sources imported from the given file are listed here. The array ismNumLightsin size.mNumCameras– The number of cameras in the scene. Cameras are fully optional, in most cases this attribute will be 0mCameras– 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– 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.
mPrivate– Internal use only, do not touch!
Layout
struct aiScene { unsigned int mFlags;struct aiNode* mRootNode; unsigned int mNumMeshes;struct aiMesh** mMeshes; unsigned int mNumMaterials;struct aiMaterial** mMaterials; unsigned int mNumAnimations;struct aiAnimation** mAnimations; unsigned int mNumTextures;struct aiTexture** mTextures; unsigned int mNumLights;struct aiLight** mLights; unsigned int mNumCameras;struct aiCamera** mCameras;struct aiMetadata* mMetaData; 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
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 Modifier and Type Method Description static AIScenecalloc()Returns a newAISceneinstance allocated withmemCalloc.static AIScene.Buffercalloc(int capacity)Returns a newAIScene.Bufferinstance allocated withmemCalloc.static AIScenecallocStack()Returns a newAISceneinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static AIScene.BuffercallocStack(int capacity)Returns a newAIScene.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static AIScene.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIScene.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static AIScenecallocStack(org.lwjgl.system.MemoryStack stack)Returns a newAISceneinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.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 AIScenemallocStack()Returns a newAISceneinstance allocated on the thread-localMemoryStack.static AIScene.BuffermallocStack(int capacity)Returns a newAIScene.Bufferinstance allocated on the thread-localMemoryStack.static AIScene.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newAIScene.Bufferinstance allocated on the specifiedMemoryStack.static AIScenemallocStack(org.lwjgl.system.MemoryStack stack)Returns a newAISceneinstance allocated on the specifiedMemoryStack.org.lwjgl.PointerBuffermAnimations()Returns aPointerBufferview of the data pointed to by themAnimationsfield.AIScenemAnimations(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themAnimationsfield.org.lwjgl.PointerBuffermCameras()Returns aPointerBufferview of the data pointed to by themCamerasfield.AIScenemCameras(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themCamerasfield.intmFlags()Returns the value of themFlagsfield.AIScenemFlags(int value)Sets the specified value to themFlagsfield.org.lwjgl.PointerBuffermLights()Returns aPointerBufferview of the data pointed to by themLightsfield.AIScenemLights(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themLightsfield.org.lwjgl.PointerBuffermMaterials()Returns aPointerBufferview of the data pointed to by themMaterialsfield.AIScenemMaterials(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themMaterialsfield.org.lwjgl.PointerBuffermMeshes()Returns aPointerBufferview of the data pointed to by themMeshesfield.AIScenemMeshes(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themMeshesfield.AIMetaDatamMetaData()Returns aAIMetaDataview of the struct pointed to by themMetaDatafield.AIScenemMetaData(AIMetaData value)Sets the address of the specifiedAIMetaDatato themMetaDatafield.intmNumAnimations()Returns the value of themNumAnimationsfield.intmNumCameras()Returns the value of themNumCamerasfield.intmNumLights()Returns the value of themNumLightsfield.intmNumMaterials()Returns the value of themNumMaterialsfield.intmNumMeshes()Returns the value of themNumMeshesfield.intmNumTextures()Returns the value of themNumTexturesfield.AINodemRootNode()Returns aAINodeview of the struct pointed to by themRootNodefield.AIScenemRootNode(AINode value)Sets the address of the specifiedAINodeto themRootNodefield.org.lwjgl.PointerBuffermTextures()Returns aPointerBufferview of the data pointed to by themTexturesfield.AIScenemTextures(org.lwjgl.PointerBuffer value)Sets the address of the specifiedPointerBufferto themTexturesfield.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 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)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.static voidvalidate(long array, int count)Callsvalidate(long)for each struct contained in the specified struct array.
-
-
-
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()
Returns the value of themFlagsfield.
-
mRootNode
@Nullable public AINode mRootNode()
Returns aAINodeview of the struct pointed to by themRootNodefield.
-
mNumMeshes
public int mNumMeshes()
Returns the value of themNumMeshesfield.
-
mMeshes
@Nullable public org.lwjgl.PointerBuffer mMeshes()
Returns aPointerBufferview of the data pointed to by themMeshesfield.
-
mNumMaterials
public int mNumMaterials()
Returns the value of themNumMaterialsfield.
-
mMaterials
@Nullable public org.lwjgl.PointerBuffer mMaterials()
Returns aPointerBufferview of the data pointed to by themMaterialsfield.
-
mNumAnimations
public int mNumAnimations()
Returns the value of themNumAnimationsfield.
-
mAnimations
@Nullable public org.lwjgl.PointerBuffer mAnimations()
Returns aPointerBufferview of the data pointed to by themAnimationsfield.
-
mNumTextures
public int mNumTextures()
Returns the value of themNumTexturesfield.
-
mTextures
@Nullable public org.lwjgl.PointerBuffer mTextures()
Returns aPointerBufferview of the data pointed to by themTexturesfield.
-
mNumLights
public int mNumLights()
Returns the value of themNumLightsfield.
-
mLights
@Nullable public org.lwjgl.PointerBuffer mLights()
Returns aPointerBufferview of the data pointed to by themLightsfield.
-
mNumCameras
public int mNumCameras()
Returns the value of themNumCamerasfield.
-
mCameras
@Nullable public org.lwjgl.PointerBuffer mCameras()
Returns aPointerBufferview of the data pointed to by themCamerasfield.
-
mMetaData
@Nullable public AIMetaData mMetaData()
Returns aAIMetaDataview of the struct pointed to by themMetaDatafield.
-
mFlags
public AIScene mFlags(int value)
Sets the specified value to themFlagsfield.
-
mRootNode
public AIScene mRootNode(@Nullable AINode value)
Sets the address of the specifiedAINodeto themRootNodefield.
-
mMeshes
public AIScene mMeshes(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themMeshesfield.
-
mMaterials
public AIScene mMaterials(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themMaterialsfield.
-
mAnimations
public AIScene mAnimations(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themAnimationsfield.
-
mTextures
public AIScene mTextures(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themTexturesfield.
-
mLights
public AIScene mLights(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themLightsfield.
-
mCameras
public AIScene mCameras(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBufferto themCamerasfield.
-
mMetaData
public AIScene mMetaData(@Nullable AIMetaData value)
Sets the address of the specifiedAIMetaDatato themMetaDatafield.
-
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)
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
public static AIScene mallocStack()
Returns a newAISceneinstance allocated on the thread-localMemoryStack.
-
callocStack
public static AIScene callocStack()
Returns a newAISceneinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static AIScene mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newAISceneinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static AIScene callocStack(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
-
mallocStack
public static AIScene.Buffer mallocStack(int capacity)
Returns a newAIScene.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static AIScene.Buffer callocStack(int capacity)
Returns a newAIScene.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static AIScene.Buffer mallocStack(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
-
callocStack
public static AIScene.Buffer callocStack(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
-
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
-
-