Package org.lwjgl.util.par
Class ParSLMesh
- All Implemented Interfaces:
Pointer
struct parsl_mesh {
uint32_t num_vertices;
uint32_t num_triangles;
uint32_t * triangle_indices;
{@link ParSLPosition parsl_position} * positions;
{@link ParSLAnnotation parsl_annotation} * annotations;
float * spine_lengths;
float * random_offsets;
}
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
The struct alignment in bytes.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct size in bytes.static final int
The struct member offsets.static final int
The struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorsConstructorDescriptionParSLMesh
(ByteBuffer container) Creates aParSLMesh
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescription@Nullable ParSLAnnotation.Buffer
static ParSLMesh
create
(long address) Returns a newParSLMesh
instance for the specified memory address.static ParSLMesh.Buffer
create
(long address, int capacity) Create aParSLMesh.Buffer
instance at the specified memory.static @Nullable ParSLMesh
createSafe
(long address) static @Nullable ParSLMesh.Buffer
createSafe
(long address, int capacity) static @Nullable ParSLAnnotation.Buffer
nannotations
(long struct) Unsafe version ofannotations()
.static int
nnum_triangles
(long struct) Unsafe version ofnum_triangles()
.static int
nnum_vertices
(long struct) Unsafe version ofnum_vertices()
.static ParSLPosition.Buffer
npositions
(long struct) Unsafe version ofpositions()
.static @Nullable FloatBuffer
nrandom_offsets
(long struct) Unsafe version ofrandom_offsets
.static @Nullable FloatBuffer
nspine_lengths
(long struct) Unsafe version ofspine_lengths
.static IntBuffer
ntriangle_indices
(long struct, int capacity) Unsafe version oftriangle_indices
.int
int
@Nullable FloatBuffer
int
sizeof()
Returnssizeof(struct)
.@Nullable FloatBuffer
triangle_indices
(int capacity) Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
NUM_VERTICES
public static final int NUM_VERTICESThe struct member offsets. -
NUM_TRIANGLES
public static final int NUM_TRIANGLESThe struct member offsets. -
TRIANGLE_INDICES
public static final int TRIANGLE_INDICESThe struct member offsets. -
POSITIONS
public static final int POSITIONSThe struct member offsets. -
ANNOTATIONS
public static final int ANNOTATIONSThe struct member offsets. -
SPINE_LENGTHS
public static final int SPINE_LENGTHSThe struct member offsets. -
RANDOM_OFFSETS
public static final int RANDOM_OFFSETSThe struct member offsets.
-
-
Constructor Details
-
ParSLMesh
Creates aParSLMesh
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 Details
-
sizeof
public int sizeof()Description copied from class:Struct
Returnssizeof(struct)
. -
num_vertices
public int num_vertices()- Returns:
- the value of the
num_vertices
field.
-
num_triangles
public int num_triangles()- Returns:
- the value of the
num_triangles
field.
-
triangle_indices
- Returns:
- a
IntBuffer
view of the data pointed to by thetriangle_indices
field.
-
positions
- Returns:
- a
ParSLPosition.Buffer
view of the struct array pointed to by thepositions
field.
-
annotations
- Returns:
- a
ParSLAnnotation.Buffer
view of the struct array pointed to by theannotations
field.
-
spine_lengths
- Returns:
- a
FloatBuffer
view of the data pointed to by thespine_lengths
field.
-
random_offsets
- Returns:
- a
FloatBuffer
view of the data pointed to by therandom_offsets
field.
-
create
Returns a newParSLMesh
instance for the specified memory address. -
createSafe
-
create
Create aParSLMesh.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
-
nnum_vertices
public static int nnum_vertices(long struct) Unsafe version ofnum_vertices()
. -
nnum_triangles
public static int nnum_triangles(long struct) Unsafe version ofnum_triangles()
. -
ntriangle_indices
Unsafe version oftriangle_indices
. -
npositions
Unsafe version ofpositions()
. -
nannotations
Unsafe version ofannotations()
. -
nspine_lengths
Unsafe version ofspine_lengths
. -
nrandom_offsets
Unsafe version ofrandom_offsets
.
-