Enum Class VertexBuffer.Type
- All Implemented Interfaces:
Serializable
,Comparable<VertexBuffer.Type>
,Constable
- Enclosing class:
- VertexBuffer
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantDescriptionInitial vertex normals, used with animation.Initial vertex position, used with animation.Initial vertex tangents, used with animation.Binormal vector, normalized (3 floats, optional)Bone indices, used with animation (4 ubytes).Bone weights, used with animation (4 floats).Color and Alpha (4 floats)Bone indices, used with animation (4 ubytes).Bone weights, used with animation (4 floats).Specifies the index buffer, must contain integer data (ubyte, ushort, or uint).Information about this instance.Specifies the source data for various vertex buffers when interleaving is used.Morph animations targets.Normal vector, normalized (3 floats).Position of the vertex (3 floats)Deprecated.The size of the point when using point buffers (float).Tangent vector, normalized (4 floats) (x,y,z,w).Texture coordinate (2 float)Texture coordinate #2Texture coordinate #3Texture coordinate #4Texture coordinate #5Texture coordinate #6Texture coordinate #7Texture coordinate #8 -
Method Summary
Modifier and TypeMethodDescriptionstatic VertexBuffer.Type
Returns the enum constant of this class with the specified name.static VertexBuffer.Type[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
Position
Position of the vertex (3 floats) -
Size
The size of the point when using point buffers (float). -
Normal
Normal vector, normalized (3 floats). -
TexCoord
Texture coordinate (2 float) -
Color
Color and Alpha (4 floats) -
Tangent
Tangent vector, normalized (4 floats) (x,y,z,w). The w component is called the binormal parity, is not normalized, and is either 1f or -1f. It's used to compute the direction on the binormal vector on the GPU at render time. -
Binormal
Binormal vector, normalized (3 floats, optional) -
InterleavedData
Specifies the source data for various vertex buffers when interleaving is used. By default, the format is byte. -
Reserved0
Deprecated.Do not use. -
Index
Specifies the index buffer, must contain integer data (ubyte, ushort, or uint). -
BindPosePosition
Initial vertex position, used with animation. Should have the same format and size asPosition
. If used with software skinning, the usage should beVertexBuffer.Usage.CpuOnly
, and the buffer should be allocated on the heap. -
BindPoseNormal
Initial vertex normals, used with animation. Should have the same format and size asNormal
. If used with software skinning, the usage should beVertexBuffer.Usage.CpuOnly
, and the buffer should be allocated on the heap. -
BoneWeight
Bone weights, used with animation (4 floats). Only used for software skinning, the usage should beVertexBuffer.Usage.CpuOnly
, and the buffer should be allocated on the heap. -
BoneIndex
Bone indices, used with animation (4 ubytes). Only used for software skinning, the usage should beVertexBuffer.Usage.CpuOnly
, and the buffer should be allocated on the heap as a ubytes buffer. -
TexCoord2
Texture coordinate #2 -
TexCoord3
Texture coordinate #3 -
TexCoord4
Texture coordinate #4 -
TexCoord5
Texture coordinate #5 -
TexCoord6
Texture coordinate #6 -
TexCoord7
Texture coordinate #7 -
TexCoord8
Texture coordinate #8 -
BindPoseTangent
Initial vertex tangents, used with animation. Should have the same format and size asTangent
. If used with software skinning, the usage should beVertexBuffer.Usage.CpuOnly
, and the buffer should be allocated on the heap. -
HWBoneWeight
Bone weights, used with animation (4 floats). for Hardware Skinning only -
HWBoneIndex
Bone indices, used with animation (4 ubytes). for Hardware Skinning only either an int or float buffer due to shader attribute types restrictions. -
InstanceData
Information about this instance. Format should beVertexBuffer.Format.Float
and number of components should be 16. -
MorphTarget0
Morph animations targets. Supports up tp 14 morph target buffers at the same time Limited due to the limited number of attributes you can bind to a vertex shader usually 16MorphTarget buffers are either POSITION, NORMAL or TANGENT buffers. So we can support up to 14 simultaneous POSITION targets 7 simultaneous POSITION and NORMAL targets 4 simultaneous POSITION, NORMAL and TANGENT targets.
Note that the MorphControl will find how many buffers can be supported for each mesh/material combination. Note that all buffers have 3 components (Vector3f) even the Tangent buffer that does not contain the w (handedness) component that will not be interpolated for morph animation.
Note that those buffers contain the difference between the base buffer (POSITION, NORMAL or TANGENT) and the target value So that you can interpolate with a MADD operation in the vertex shader position = weight * diffPosition + basePosition;
-
MorphTarget1
-
MorphTarget2
-
MorphTarget3
-
MorphTarget4
-
MorphTarget5
-
MorphTarget6
-
MorphTarget7
-
MorphTarget8
-
MorphTarget9
-
MorphTarget10
-
MorphTarget11
-
MorphTarget12
-
MorphTarget13
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-