Package com.mojang.blaze3d.vertex
Class VertexBuffer
java.lang.Object
com.mojang.blaze3d.vertex.VertexBuffer
- All Implemented Interfaces:
AutoCloseable
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate intprivate VertexFormatprivate intprivate intprivate VertexFormat.IndexTypeprivate VertexFormat.Modeprivate final VertexBuffer.Usageprivate int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate void_drawWithShader(org.joml.Matrix4f pModelViewMatrix, org.joml.Matrix4f pProjectionMatrix, ShaderInstance pShader) voidbind()voidclose()voiddraw()voiddrawWithShader(org.joml.Matrix4f pModelViewMatrix, org.joml.Matrix4f pProjectionMatrix, ShaderInstance pShader) private VertexFormat.IndexTypebooleanstatic voidunbind()voidvoiduploadIndexBuffer(MeshData.DrawState pDrawState, ByteBuffer pBuffer) private VertexFormatuploadVertexBuffer(MeshData.DrawState pDrawState, ByteBuffer pBuffer)
-
Field Details
-
usage
-
vertexBufferId
private int vertexBufferId -
indexBufferId
private int indexBufferId -
arrayObjectId
private int arrayObjectId -
format
-
sequentialIndices
-
indexType
-
indexCount
private int indexCount -
mode
-
-
Constructor Details
-
VertexBuffer
-
-
Method Details
-
upload
-
uploadIndexBuffer
-
uploadVertexBuffer
private VertexFormat uploadVertexBuffer(MeshData.DrawState pDrawState, @Nullable ByteBuffer pBuffer) -
uploadIndexBuffer
@Nullable private RenderSystem.AutoStorageIndexBuffer uploadIndexBuffer(MeshData.DrawState pDrawState, @Nullable ByteBuffer pBuffer) -
bind
public void bind() -
unbind
public static void unbind() -
draw
public void draw() -
getIndexType
-
drawWithShader
public void drawWithShader(org.joml.Matrix4f pModelViewMatrix, org.joml.Matrix4f pProjectionMatrix, ShaderInstance pShader) -
_drawWithShader
private void _drawWithShader(org.joml.Matrix4f pModelViewMatrix, org.joml.Matrix4f pProjectionMatrix, ShaderInstance pShader) -
close
public void close()- Specified by:
closein interfaceAutoCloseable
-
getFormat
-
isInvalid
public boolean isInvalid()
-