Class AIMesh
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.assimp.AIMesh
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class AIMesh extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
A mesh represents a geometry or model with a single material.It usually consists of a number of vertices and a series of primitives/faces referencing the vertices. In addition there might be a series of bones, each of them addressing a number of vertices with a certain weight. Vertex data is presented in channels with each channel containing a single per-vertex information such as a set of texture coordinates or a normal vector. If a data pointer is non-null, the corresponding data stream is present.
A Mesh uses only a single material which is referenced by a material ID.
Layout
struct aiMesh { unsigned int
mPrimitiveTypes()
; unsigned intmNumVertices()
; unsigned intmNumFaces()
;struct aiVector3D
*mVertices()
;struct aiVector3D
*mNormals()
;struct aiVector3D
*mTangents()
;struct aiVector3D
*mBitangents()
;struct aiColor4D
*mColors()
[AI_MAX_NUMBER_OF_COLOR_SETS];struct aiVector3D
*mTextureCoords()
[AI_MAX_NUMBER_OF_TEXTURECOORDS]; unsigned intmNumUVComponents()
[AI_MAX_NUMBER_OF_TEXTURECOORDS];struct aiFace
*mFaces()
; unsigned intmNumBones()
;struct aiBone
**mBones()
; unsigned intmMaterialIndex()
;struct aiString
mName()
; unsigned intmNumAnimMeshes()
;struct aiAnimMesh
**mAnimMeshes()
; unsigned intmMethod()
;struct aiAABB
mAABB()
;struct aiString
**mTextureCoordsNames()
; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
AIMesh.Buffer
An array ofAIMesh
structs.
-
Field Summary
Fields Modifier and Type Field Description static int
ALIGNOF
The struct alignment in bytes.static int
MAABB
MANIMMESHES
MBITANGENTS
MBONES
MCOLORS
MFACES
MMATERIALINDEX
MMETHOD
MNAME
MNORMALS
MNUMANIMMESHES
MNUMBONES
MNUMFACES
MNUMUVCOMPONENTS
MNUMVERTICES
MPRIMITIVETYPES
MTANGENTS
MTEXTURECOORDS
MTEXTURECOORDSNAMES
MVERTICESThe struct member offsets.static int
SIZEOF
The struct size in bytes.
-
Constructor Summary
Constructors Constructor Description AIMesh(java.nio.ByteBuffer container)
Creates aAIMesh
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 AIMesh
calloc()
Returns a newAIMesh
instance allocated withmemCalloc
.static AIMesh.Buffer
calloc(int capacity)
Returns a newAIMesh.Buffer
instance allocated withmemCalloc
.static AIMesh.Buffer
calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static AIMesh
calloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static AIMesh
callocStack()
Deprecated.static AIMesh.Buffer
callocStack(int capacity)
Deprecated.static AIMesh.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.static AIMesh
callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.static AIMesh
create()
Returns a newAIMesh
instance allocated withBufferUtils
.static AIMesh.Buffer
create(int capacity)
Returns a newAIMesh.Buffer
instance allocated withBufferUtils
.static AIMesh
create(long address)
Returns a newAIMesh
instance for the specified memory address.static AIMesh.Buffer
create(long address, int capacity)
Create aAIMesh.Buffer
instance at the specified memory.static AIMesh
createSafe(long address)
static AIMesh.Buffer
createSafe(long address, int capacity)
AIAABB
mAABB()
the bounding boxAIMesh
mAABB(java.util.function.Consumer<AIAABB> consumer)
Passes themAABB()
field to the specifiedConsumer
.AIMesh
mAABB(AIAABB value)
static AIMesh
malloc()
Returns a newAIMesh
instance allocated withmemAlloc
.static AIMesh.Buffer
malloc(int capacity)
Returns a newAIMesh.Buffer
instance allocated withmemAlloc
.static AIMesh.Buffer
malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh.Buffer
instance allocated on the specifiedMemoryStack
.static AIMesh
malloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh
instance allocated on the specifiedMemoryStack
.static AIMesh
mallocStack()
Deprecated.static AIMesh.Buffer
mallocStack(int capacity)
Deprecated.static AIMesh.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.static AIMesh
mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.org.lwjgl.PointerBuffer
mAnimMeshes()
Attachment meshes for this mesh, for vertex-based animation.AIMesh
mAnimMeshes(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themAnimMeshes()
field.AIVector3D.Buffer
mBitangents()
Vertex bitangents.AIMesh
mBitangents(AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themBitangents()
field.org.lwjgl.PointerBuffer
mBones()
The bones of this mesh.AIMesh
mBones(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themBones()
field.org.lwjgl.PointerBuffer
mColors()
Vertex color sets.AIColor4D.Buffer
mColors(int index)
Vertex color sets.AIMesh
mColors(int index, java.util.function.Consumer<AIColor4D.Buffer> consumer)
AIMesh
mColors(int index, AIColor4D.Buffer value)
Copies the address of the specifiedAIColor4D.Buffer
at the specified index of themColors()
field.AIMesh
mColors(org.lwjgl.PointerBuffer value)
Copies the specifiedPointerBuffer
to themColors()
field.AIFace.Buffer
mFaces()
The faces the mesh is constructed from.AIMesh
mFaces(AIFace.Buffer value)
Sets the address of the specifiedAIFace.Buffer
to themFaces()
field.int
mMaterialIndex()
The material used by this mesh.AIMesh
mMaterialIndex(int value)
Sets the specified value to themMaterialIndex()
field.int
mMethod()
Method of morphing when anim-meshes are specified.AIMesh
mMethod(int value)
Sets the specified value to themMethod()
field.AIString
mName()
Name of the mesh.AIMesh
mName(java.util.function.Consumer<AIString> consumer)
Passes themName()
field to the specifiedConsumer
.AIMesh
mName(AIString value)
AIVector3D.Buffer
mNormals()
Vertex normals.AIMesh
mNormals(AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themNormals()
field.int
mNumAnimMeshes()
The number of attachment meshes.int
mNumBones()
The number of bones this mesh contains.int
mNumFaces()
The number of primitives (triangles, polygons, lines) in this mesh.java.nio.IntBuffer
mNumUVComponents()
Specifies the number of components for a given UV channel.int
mNumUVComponents(int index)
Specifies the number of components for a given UV channel.AIMesh
mNumUVComponents(int index, int value)
Sets the specified value at the specified index of themNumUVComponents()
field.AIMesh
mNumUVComponents(java.nio.IntBuffer value)
Copies the specifiedIntBuffer
to themNumUVComponents()
field.int
mNumVertices()
The number of vertices in this mesh.AIMesh
mNumVertices(int value)
Sets the specified value to themNumVertices()
field.int
mPrimitiveTypes()
Bitwise combination of the members of theaiPrimitiveType
enum.AIMesh
mPrimitiveTypes(int value)
Sets the specified value to themPrimitiveTypes()
field.AIVector3D.Buffer
mTangents()
Vertex tangents.AIMesh
mTangents(AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themTangents()
field.org.lwjgl.PointerBuffer
mTextureCoords()
Vertex texture coordinates, also known as UV channels.AIVector3D.Buffer
mTextureCoords(int index)
Vertex texture coordinates, also known as UV channels.AIMesh
mTextureCoords(int index, java.util.function.Consumer<AIVector3D.Buffer> consumer)
AIMesh
mTextureCoords(int index, AIVector3D.Buffer value)
Copies the address of the specifiedAIVector3D.Buffer
at the specified index of themTextureCoords()
field.AIMesh
mTextureCoords(org.lwjgl.PointerBuffer value)
Copies the specifiedPointerBuffer
to themTextureCoords()
field.org.lwjgl.PointerBuffer
mTextureCoordsNames()
Vertex UV stream names.AIMesh
mTextureCoordsNames(org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themTextureCoordsNames()
field.AIVector3D.Buffer
mVertices()
Vertex positions.AIMesh
mVertices(AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themVertices()
field.static AIAABB
nmAABB(long struct)
Unsafe version ofmAABB()
.static void
nmAABB(long struct, AIAABB value)
Unsafe version ofmAABB
.static org.lwjgl.PointerBuffer
nmAnimMeshes(long struct)
Unsafe version ofmAnimMeshes
.static void
nmAnimMeshes(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmAnimMeshes
.static AIVector3D.Buffer
nmBitangents(long struct)
Unsafe version ofmBitangents()
.static void
nmBitangents(long struct, AIVector3D.Buffer value)
Unsafe version ofmBitangents
.static org.lwjgl.PointerBuffer
nmBones(long struct)
Unsafe version ofmBones
.static void
nmBones(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmBones
.static org.lwjgl.PointerBuffer
nmColors(long struct)
Unsafe version ofmColors()
.static AIColor4D.Buffer
nmColors(long struct, int index)
Unsafe version ofmColors
.static void
nmColors(long struct, int index, AIColor4D.Buffer value)
Unsafe version ofmColors
.static void
nmColors(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmColors
.static AIFace.Buffer
nmFaces(long struct)
Unsafe version ofmFaces()
.static void
nmFaces(long struct, AIFace.Buffer value)
Unsafe version ofmFaces
.static int
nmMaterialIndex(long struct)
Unsafe version ofmMaterialIndex()
.static void
nmMaterialIndex(long struct, int value)
Unsafe version ofmMaterialIndex
.static int
nmMethod(long struct)
Unsafe version ofmMethod()
.static void
nmMethod(long struct, int value)
Unsafe version ofmMethod
.static AIString
nmName(long struct)
Unsafe version ofmName()
.static void
nmName(long struct, AIString value)
Unsafe version ofmName
.static AIVector3D.Buffer
nmNormals(long struct)
Unsafe version ofmNormals()
.static void
nmNormals(long struct, AIVector3D.Buffer value)
Unsafe version ofmNormals
.static int
nmNumAnimMeshes(long struct)
Unsafe version ofmNumAnimMeshes()
.static void
nmNumAnimMeshes(long struct, int value)
Sets the specified value to themNumAnimMeshes
field of the specifiedstruct
.static int
nmNumBones(long struct)
Unsafe version ofmNumBones()
.static void
nmNumBones(long struct, int value)
Sets the specified value to themNumBones
field of the specifiedstruct
.static int
nmNumFaces(long struct)
Unsafe version ofmNumFaces()
.static void
nmNumFaces(long struct, int value)
Sets the specified value to themNumFaces
field of the specifiedstruct
.static java.nio.IntBuffer
nmNumUVComponents(long struct)
Unsafe version ofmNumUVComponents()
.static int
nmNumUVComponents(long struct, int index)
Unsafe version ofmNumUVComponents
.static void
nmNumUVComponents(long struct, int index, int value)
Unsafe version ofmNumUVComponents
.static void
nmNumUVComponents(long struct, java.nio.IntBuffer value)
Unsafe version ofmNumUVComponents
.static int
nmNumVertices(long struct)
Unsafe version ofmNumVertices()
.static void
nmNumVertices(long struct, int value)
Sets the specified value to themNumVertices
field of the specifiedstruct
.static int
nmPrimitiveTypes(long struct)
Unsafe version ofmPrimitiveTypes()
.static void
nmPrimitiveTypes(long struct, int value)
Unsafe version ofmPrimitiveTypes
.static AIVector3D.Buffer
nmTangents(long struct)
Unsafe version ofmTangents()
.static void
nmTangents(long struct, AIVector3D.Buffer value)
Unsafe version ofmTangents
.static org.lwjgl.PointerBuffer
nmTextureCoords(long struct)
Unsafe version ofmTextureCoords()
.static AIVector3D.Buffer
nmTextureCoords(long struct, int index)
Unsafe version ofmTextureCoords
.static void
nmTextureCoords(long struct, int index, AIVector3D.Buffer value)
Unsafe version ofmTextureCoords
.static void
nmTextureCoords(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmTextureCoords
.static org.lwjgl.PointerBuffer
nmTextureCoordsNames(long struct)
Unsafe version ofmTextureCoordsNames
.static void
nmTextureCoordsNames(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmTextureCoordsNames
.static AIVector3D.Buffer
nmVertices(long struct)
Unsafe version ofmVertices()
.static void
nmVertices(long struct, AIVector3D.Buffer value)
Unsafe version ofmVertices
.AIMesh
set(int mPrimitiveTypes, int mNumVertices, AIVector3D.Buffer mVertices, AIVector3D.Buffer mNormals, AIVector3D.Buffer mTangents, AIVector3D.Buffer mBitangents, org.lwjgl.PointerBuffer mColors, org.lwjgl.PointerBuffer mTextureCoords, java.nio.IntBuffer mNumUVComponents, AIFace.Buffer mFaces, org.lwjgl.PointerBuffer mBones, int mMaterialIndex, AIString mName, org.lwjgl.PointerBuffer mAnimMeshes, int mMethod, AIAABB mAABB, org.lwjgl.PointerBuffer mTextureCoordsNames)
Initializes this struct with the specified values.AIMesh
set(AIMesh src)
Copies the specified struct data to this struct.int
sizeof()
static void
validate(long struct)
Validates pointer members that should not beNULL
.
-
-
-
Field Detail
-
SIZEOF
The struct size in bytes.
-
ALIGNOF
The struct alignment in bytes.
-
MPRIMITIVETYPES, MNUMVERTICES, MNUMFACES, MVERTICES, MNORMALS, MTANGENTS, MBITANGENTS, MCOLORS, MTEXTURECOORDS, MNUMUVCOMPONENTS, MFACES, MNUMBONES, MBONES, MMATERIALINDEX, MNAME, MNUMANIMMESHES, MANIMMESHES, MMETHOD, MAABB, MTEXTURECOORDSNAMES
The struct member offsets.
-
-
Constructor Detail
-
AIMesh
public AIMesh(java.nio.ByteBuffer container)
Creates aAIMesh
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
-
mPrimitiveTypes
public int mPrimitiveTypes()
Bitwise combination of the members of theaiPrimitiveType
enum. This specifies which types of primitives are present in the mesh. The "SortByPrimitiveType"-Step can be used to make sure the output meshes consist of one primitive type each. One or more of:PrimitiveType_POINT
PrimitiveType_LINE
PrimitiveType_TRIANGLE
PrimitiveType_POLYGON
PrimitiveType_NGONEncodingFlag
-
mNumVertices
public int mNumVertices()
The number of vertices in this mesh. This is also the size of all of the per-vertex data arrays. The maximum value for this member isAssimp.AI_MAX_VERTICES
.
-
mNumFaces
public int mNumFaces()
The number of primitives (triangles, polygons, lines) in this mesh. This is also the size of themFaces
array. The maximum value for this member isAssimp.AI_MAX_FACES
.
-
mVertices
public AIVector3D.Buffer mVertices()
Vertex positions. This array is always present in a mesh. The array ismNumVertices
in size.
-
mNormals
@Nullable public AIVector3D.Buffer mNormals()
Vertex normals.The array contains normalized vectors,
NULL
if not present. The array ismNumVertices
in size. Normals are undefined for point and line primitives. A mesh consisting of points and lines only may not have normal vectors. Meshes with mixed primitive types (i.e. lines and triangles) may have normals, but the normals for vertices that are only referenced by point or line primitives are undefined and set toqNaN
.Note
Normal vectors computed by Assimp are always unit-length. However, this needn't apply for normals that have been taken directly from the model file
-
mTangents
@Nullable public AIVector3D.Buffer mTangents()
Vertex tangents.The tangent of a vertex points in the direction of the positive X texture axis. The array contains normalized vectors,
NULL
if not present. The array ismNumVertices
in size. A mesh consisting of points and lines only may not have normal vectors. Meshes with mixed primitive types (i.e. lines and triangles) may have normals, but the normals for vertices that are only referenced by point or line primitives are undefined and set toqNaN
.Note
If the mesh contains tangents, it automatically also contains bitangents.
-
mBitangents
@Nullable public AIVector3D.Buffer mBitangents()
Vertex bitangents.The bitangent of a vertex points in the direction of the positive Y texture axis. The array contains normalized vectors,
NULL
if not present. The array ismNumVertices
in size.Note
If the mesh contains tangents, it automatically also contains bitangents.
-
mColors
public org.lwjgl.PointerBuffer mColors() @Nullable public AIColor4D.Buffer mColors(int index)
Vertex color sets. A mesh may contain 0 toAssimp.AI_MAX_NUMBER_OF_COLOR_SETS
vertex colors per vertex.NULL
if not present. Each array ismNumVertices
in size if present.
-
mTextureCoords
public org.lwjgl.PointerBuffer mTextureCoords() @Nullable public AIVector3D.Buffer mTextureCoords(int index)
Vertex texture coordinates, also known as UV channels. A mesh may contain 0 toAssimp.AI_MAX_NUMBER_OF_TEXTURECOORDS
per vertex.NULL
if not present. The array ismNumVertices
in size.
-
mNumUVComponents
public java.nio.IntBuffer mNumUVComponents() public int mNumUVComponents(int index)
Specifies the number of components for a given UV channel. Up to three channels are supported (UVW, for accessing volume or cube maps). If the value is 2 for a given channel n, the componentp.z
ofmTextureCoords[n][p]
is set to 0.0f. If the value is 1 for a given channel,p.y
is set to 0.0f, too.Note: 4D coordinates are not supported.
-
mFaces
public AIFace.Buffer mFaces()
The faces the mesh is constructed from. Each face refers to a number of vertices by their indices. This array is always present in a mesh, its size is given inmNumFaces
. If theAssimp.AI_SCENE_FLAGS_NON_VERBOSE_FORMAT
is NOT set each face references an unique set of vertices.
-
mNumBones
public int mNumBones()
The number of bones this mesh contains. Can be 0, in which case themBones
array isNULL
.
-
mBones
@Nullable public org.lwjgl.PointerBuffer mBones()
The bones of this mesh. A bone consists of a name by which it can be found in the frame hierarchy and a set of vertex weights.
-
mMaterialIndex
public int mMaterialIndex()
The material used by this mesh. A mesh uses only a single material. If an imported model uses multiple materials, the import splits up the mesh. Use this value as index into the scene's material list.
-
mName
public AIString mName()
Name of the mesh.Meshes can be named, but this is not a requirement and leaving this field empty is totally fine. There are mainly three uses for mesh names:
- some formats name nodes and meshes independently.
- importers tend to split meshes up to meet the one-material-per-mesh requirement. Assigning the same (dummy) name to each of the result meshes aids the caller at recovering the original mesh partitioning.
- vertex animations refer to meshes by their names.
-
mNumAnimMeshes
public int mNumAnimMeshes()
The number of attachment meshes. Note! Currently only works with Collada loader.
-
mAnimMeshes
@Nullable public org.lwjgl.PointerBuffer mAnimMeshes()
Attachment meshes for this mesh, for vertex-based animation. Attachment meshes carry replacement data for some of the mesh'es vertex components (usually positions, normals). Note! Currently only works with Collada loader.
-
mMethod
public int mMethod()
Method of morphing when anim-meshes are specified. One of:MorphingMethod_VERTEX_BLEND
MorphingMethod_MORPH_NORMALIZED
MorphingMethod_MORPH_RELATIVE
-
mAABB
public AIAABB mAABB()
the bounding box
-
mTextureCoordsNames
@Nullable public org.lwjgl.PointerBuffer mTextureCoordsNames()
Vertex UV stream names. Pointer to array of sizeAssimp.AI_MAX_NUMBER_OF_TEXTURECOORDS
.
-
mPrimitiveTypes
public AIMesh mPrimitiveTypes(int value)
Sets the specified value to themPrimitiveTypes()
field.
-
mNumVertices
public AIMesh mNumVertices(int value)
Sets the specified value to themNumVertices()
field.
-
mVertices
public AIMesh mVertices(AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themVertices()
field.
-
mNormals
public AIMesh mNormals(@Nullable AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themNormals()
field.
-
mTangents
public AIMesh mTangents(@Nullable AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themTangents()
field.
-
mBitangents
public AIMesh mBitangents(@Nullable AIVector3D.Buffer value)
Sets the address of the specifiedAIVector3D.Buffer
to themBitangents()
field.
-
mColors
public AIMesh mColors(org.lwjgl.PointerBuffer value)
Copies the specifiedPointerBuffer
to themColors()
field.
-
mColors
public AIMesh mColors(int index, @Nullable AIColor4D.Buffer value)
Copies the address of the specifiedAIColor4D.Buffer
at the specified index of themColors()
field.
-
mColors
public AIMesh mColors(int index, java.util.function.Consumer<AIColor4D.Buffer> consumer)
-
mTextureCoords
public AIMesh mTextureCoords(org.lwjgl.PointerBuffer value)
Copies the specifiedPointerBuffer
to themTextureCoords()
field.
-
mTextureCoords
public AIMesh mTextureCoords(int index, @Nullable AIVector3D.Buffer value)
Copies the address of the specifiedAIVector3D.Buffer
at the specified index of themTextureCoords()
field.
-
mTextureCoords
public AIMesh mTextureCoords(int index, java.util.function.Consumer<AIVector3D.Buffer> consumer)
-
mNumUVComponents
public AIMesh mNumUVComponents(java.nio.IntBuffer value)
Copies the specifiedIntBuffer
to themNumUVComponents()
field.
-
mNumUVComponents
public AIMesh mNumUVComponents(int index, int value)
Sets the specified value at the specified index of themNumUVComponents()
field.
-
mFaces
public AIMesh mFaces(AIFace.Buffer value)
Sets the address of the specifiedAIFace.Buffer
to themFaces()
field.
-
mBones
public AIMesh mBones(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themBones()
field.
-
mMaterialIndex
public AIMesh mMaterialIndex(int value)
Sets the specified value to themMaterialIndex()
field.
-
mName
public AIMesh mName(java.util.function.Consumer<AIString> consumer)
Passes themName()
field to the specifiedConsumer
.
-
mAnimMeshes
public AIMesh mAnimMeshes(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themAnimMeshes()
field.
-
mAABB
public AIMesh mAABB(java.util.function.Consumer<AIAABB> consumer)
Passes themAABB()
field to the specifiedConsumer
.
-
mTextureCoordsNames
public AIMesh mTextureCoordsNames(@Nullable org.lwjgl.PointerBuffer value)
Sets the address of the specifiedPointerBuffer
to themTextureCoordsNames()
field.
-
set
public AIMesh set(int mPrimitiveTypes, int mNumVertices, AIVector3D.Buffer mVertices, @Nullable AIVector3D.Buffer mNormals, @Nullable AIVector3D.Buffer mTangents, @Nullable AIVector3D.Buffer mBitangents, org.lwjgl.PointerBuffer mColors, org.lwjgl.PointerBuffer mTextureCoords, java.nio.IntBuffer mNumUVComponents, AIFace.Buffer mFaces, @Nullable org.lwjgl.PointerBuffer mBones, int mMaterialIndex, AIString mName, @Nullable org.lwjgl.PointerBuffer mAnimMeshes, int mMethod, AIAABB mAABB, @Nullable org.lwjgl.PointerBuffer mTextureCoordsNames)
Initializes this struct with the specified values.
-
set
public AIMesh set(AIMesh src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static AIMesh malloc()
Returns a newAIMesh
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static AIMesh calloc()
Returns a newAIMesh
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static AIMesh create()
Returns a newAIMesh
instance allocated withBufferUtils
.
-
create
public static AIMesh create(long address)
Returns a newAIMesh
instance for the specified memory address.
-
createSafe
@Nullable public static AIMesh createSafe(long address)
-
malloc
public static AIMesh.Buffer malloc(int capacity)
Returns a newAIMesh.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static AIMesh.Buffer calloc(int capacity)
Returns a newAIMesh.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static AIMesh.Buffer create(int capacity)
Returns a newAIMesh.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static AIMesh.Buffer create(long address, int capacity)
Create aAIMesh.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static AIMesh.Buffer createSafe(long address, int capacity)
-
mallocStack
@Deprecated public static AIMesh mallocStack()
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead.
-
callocStack
@Deprecated public static AIMesh callocStack()
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead.
-
mallocStack
@Deprecated public static AIMesh mallocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead.
-
callocStack
@Deprecated public static AIMesh callocStack(org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead.
-
mallocStack
@Deprecated public static AIMesh.Buffer mallocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead.
-
callocStack
@Deprecated public static AIMesh.Buffer callocStack(int capacity)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead.
-
mallocStack
@Deprecated public static AIMesh.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 AIMesh.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead.
-
malloc
public static AIMesh malloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
public static AIMesh calloc(org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
public static AIMesh.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
calloc
public static AIMesh.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newAIMesh.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nmPrimitiveTypes
public static int nmPrimitiveTypes(long struct)
Unsafe version ofmPrimitiveTypes()
.
-
nmNumVertices
public static int nmNumVertices(long struct)
Unsafe version ofmNumVertices()
.
-
nmNumFaces
public static int nmNumFaces(long struct)
Unsafe version ofmNumFaces()
.
-
nmVertices
public static AIVector3D.Buffer nmVertices(long struct)
Unsafe version ofmVertices()
.
-
nmNormals
@Nullable public static AIVector3D.Buffer nmNormals(long struct)
Unsafe version ofmNormals()
.
-
nmTangents
@Nullable public static AIVector3D.Buffer nmTangents(long struct)
Unsafe version ofmTangents()
.
-
nmBitangents
@Nullable public static AIVector3D.Buffer nmBitangents(long struct)
Unsafe version ofmBitangents()
.
-
nmColors
public static org.lwjgl.PointerBuffer nmColors(long struct)
Unsafe version ofmColors()
.
-
nmColors
@Nullable public static AIColor4D.Buffer nmColors(long struct, int index)
Unsafe version ofmColors
.
-
nmTextureCoords
public static org.lwjgl.PointerBuffer nmTextureCoords(long struct)
Unsafe version ofmTextureCoords()
.
-
nmTextureCoords
@Nullable public static AIVector3D.Buffer nmTextureCoords(long struct, int index)
Unsafe version ofmTextureCoords
.
-
nmNumUVComponents
public static java.nio.IntBuffer nmNumUVComponents(long struct)
Unsafe version ofmNumUVComponents()
.
-
nmNumUVComponents
public static int nmNumUVComponents(long struct, int index)
Unsafe version ofmNumUVComponents
.
-
nmFaces
public static AIFace.Buffer nmFaces(long struct)
Unsafe version ofmFaces()
.
-
nmNumBones
public static int nmNumBones(long struct)
Unsafe version ofmNumBones()
.
-
nmBones
@Nullable public static org.lwjgl.PointerBuffer nmBones(long struct)
Unsafe version ofmBones
.
-
nmMaterialIndex
public static int nmMaterialIndex(long struct)
Unsafe version ofmMaterialIndex()
.
-
nmNumAnimMeshes
public static int nmNumAnimMeshes(long struct)
Unsafe version ofmNumAnimMeshes()
.
-
nmAnimMeshes
@Nullable public static org.lwjgl.PointerBuffer nmAnimMeshes(long struct)
Unsafe version ofmAnimMeshes
.
-
nmMethod
public static int nmMethod(long struct)
Unsafe version ofmMethod()
.
-
nmTextureCoordsNames
@Nullable public static org.lwjgl.PointerBuffer nmTextureCoordsNames(long struct)
Unsafe version ofmTextureCoordsNames
.
-
nmPrimitiveTypes
public static void nmPrimitiveTypes(long struct, int value)
Unsafe version ofmPrimitiveTypes
.
-
nmNumVertices
public static void nmNumVertices(long struct, int value)
Sets the specified value to themNumVertices
field of the specifiedstruct
.
-
nmNumFaces
public static void nmNumFaces(long struct, int value)
Sets the specified value to themNumFaces
field of the specifiedstruct
.
-
nmVertices
public static void nmVertices(long struct, AIVector3D.Buffer value)
Unsafe version ofmVertices
.
-
nmNormals
public static void nmNormals(long struct, @Nullable AIVector3D.Buffer value)
Unsafe version ofmNormals
.
-
nmTangents
public static void nmTangents(long struct, @Nullable AIVector3D.Buffer value)
Unsafe version ofmTangents
.
-
nmBitangents
public static void nmBitangents(long struct, @Nullable AIVector3D.Buffer value)
Unsafe version ofmBitangents
.
-
nmColors
public static void nmColors(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmColors
.
-
nmColors
public static void nmColors(long struct, int index, @Nullable AIColor4D.Buffer value)
Unsafe version ofmColors
.
-
nmTextureCoords
public static void nmTextureCoords(long struct, org.lwjgl.PointerBuffer value)
Unsafe version ofmTextureCoords
.
-
nmTextureCoords
public static void nmTextureCoords(long struct, int index, @Nullable AIVector3D.Buffer value)
Unsafe version ofmTextureCoords
.
-
nmNumUVComponents
public static void nmNumUVComponents(long struct, java.nio.IntBuffer value)
Unsafe version ofmNumUVComponents
.
-
nmNumUVComponents
public static void nmNumUVComponents(long struct, int index, int value)
Unsafe version ofmNumUVComponents
.
-
nmFaces
public static void nmFaces(long struct, AIFace.Buffer value)
Unsafe version ofmFaces
.
-
nmNumBones
public static void nmNumBones(long struct, int value)
Sets the specified value to themNumBones
field of the specifiedstruct
.
-
nmBones
public static void nmBones(long struct, @Nullable org.lwjgl.PointerBuffer value)
Unsafe version ofmBones
.
-
nmMaterialIndex
public static void nmMaterialIndex(long struct, int value)
Unsafe version ofmMaterialIndex
.
-
nmNumAnimMeshes
public static void nmNumAnimMeshes(long struct, int value)
Sets the specified value to themNumAnimMeshes
field of the specifiedstruct
.
-
nmAnimMeshes
public static void nmAnimMeshes(long struct, @Nullable org.lwjgl.PointerBuffer value)
Unsafe version ofmAnimMeshes
.
-
nmMethod
public static void nmMethod(long struct, int value)
Unsafe version ofmMethod
.
-
nmTextureCoordsNames
public static void nmTextureCoordsNames(long struct, @Nullable org.lwjgl.PointerBuffer value)
Unsafe version ofmTextureCoordsNames
.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-
-