Class IndexedModel
java.lang.Object
team.lodestar.lodestone.systems.model.obj.IndexedModel
- Direct Known Subclasses:
ObjModel
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected com.mojang.blaze3d.vertex.MeshDataprotected List<IndexedMesh> protected com.mojang.blaze3d.vertex.VertexBufferprotected net.minecraft.resources.ResourceLocationprotected List<ModelModifier<?>> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidbakeIndices(com.mojang.blaze3d.vertex.VertexFormat.Mode mode, boolean triangulate) voidcleanup()voidcreateMeshBuffer(com.mojang.blaze3d.vertex.PoseStack poseStack) com.mojang.blaze3d.vertex.MeshDatadrawMesh(com.mojang.blaze3d.vertex.PoseStack poseStack, com.mojang.blaze3d.vertex.Tesselator tesselator) net.minecraft.resources.ResourceLocationnet.minecraft.resources.ResourceLocationabstract voidvoidrender(com.mojang.blaze3d.vertex.PoseStack poseStack, com.mojang.blaze3d.vertex.VertexConsumer vertexConsumer, net.minecraft.client.renderer.RenderType renderType) voidrender(com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.RenderType renderType, net.minecraft.client.renderer.MultiBufferSource.BufferSource bufferSource) voidrenderInstanced(com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.RenderType renderType, int instances) voidsetMeshes(List<IndexedMesh> meshes)
-
Field Details
-
vertices
-
meshes
-
bakedIndices
-
modifiers
-
modelId
protected net.minecraft.resources.ResourceLocation modelId -
modelBuffer
protected com.mojang.blaze3d.vertex.VertexBuffer modelBuffer -
meshData
protected com.mojang.blaze3d.vertex.MeshData meshData
-
-
Constructor Details
-
IndexedModel
public IndexedModel(net.minecraft.resources.ResourceLocation modelId)
-
-
Method Details
-
render
public void render(com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.RenderType renderType, net.minecraft.client.renderer.MultiBufferSource.BufferSource bufferSource) -
render
public void render(com.mojang.blaze3d.vertex.PoseStack poseStack, com.mojang.blaze3d.vertex.VertexConsumer vertexConsumer, net.minecraft.client.renderer.RenderType renderType) -
renderInstanced
public void renderInstanced(com.mojang.blaze3d.vertex.PoseStack poseStack, net.minecraft.client.renderer.RenderType renderType, int instances) -
loadModel
public abstract void loadModel() -
applyModifiers
public void applyModifiers() -
getVertices
-
getMeshes
-
setMeshes
-
getBakedIndices
-
getModelId
public net.minecraft.resources.ResourceLocation getModelId() -
getAssetLocation
public net.minecraft.resources.ResourceLocation getAssetLocation() -
bakeIndices
public void bakeIndices(com.mojang.blaze3d.vertex.VertexFormat.Mode mode, boolean triangulate) -
createMeshBuffer
public void createMeshBuffer(com.mojang.blaze3d.vertex.PoseStack poseStack) -
drawMesh
public com.mojang.blaze3d.vertex.MeshData drawMesh(com.mojang.blaze3d.vertex.PoseStack poseStack, com.mojang.blaze3d.vertex.Tesselator tesselator) -
cleanup
public void cleanup()
-