rename vertex element

This commit is contained in:
James Seibel
2026-03-01 16:30:01 -06:00
parent dedcc875d2
commit f4171ffca1
2 changed files with 3 additions and 5 deletions
@@ -11,7 +11,7 @@ public class DhVertexFormat
public static final VertexFormatElement SCREEN_POS = VertexFormatElement.register(/*id*/7, /*index*/0, VertexFormatElement.Type.FLOAT, VertexFormatElement.Usage.POSITION, /*count*/ 2);
public static final VertexFormatElement RGBA_FLOAT_COLOR = VertexFormatElement.register(/*id*/8, /*index*/0, VertexFormatElement.Type.FLOAT, VertexFormatElement.Usage.COLOR, /*count*/ 4);
public static final VertexFormatElement SHORT_POS = VertexFormatElement.register(/*id*/9, /*index*/0, VertexFormatElement.Type.USHORT, VertexFormatElement.Usage.POSITION, /*count*/ 3);
public static final VertexFormatElement SHORT_XYZ_POS = VertexFormatElement.register(/*id*/9, /*index*/0, VertexFormatElement.Type.USHORT, VertexFormatElement.Usage.POSITION, /*count*/ 3);
public static final VertexFormatElement BYTE_PAD = VertexFormatElement.register(/*id*/10, /*index*/0, VertexFormatElement.Type.BYTE, VertexFormatElement.Usage.GENERIC, /*count*/ 1);
/** contains light and micro-offset */
public static final VertexFormatElement META = VertexFormatElement.register(/*id*/11, /*index*/0, VertexFormatElement.Type.USHORT, VertexFormatElement.Usage.GENERIC, /*count*/ 1);
@@ -16,7 +16,6 @@ import com.mojang.blaze3d.systems.RenderPass;
import com.mojang.blaze3d.systems.RenderSystem;
import com.mojang.blaze3d.textures.*;
import com.mojang.blaze3d.vertex.VertexFormat;
import com.seibel.distanthorizons.api.methods.events.sharedParameterObjects.DhApiRenderParam;
import com.seibel.distanthorizons.api.objects.math.DhApiVec3f;
import com.seibel.distanthorizons.common.wrappers.misc.LightMapWrapper;
import com.seibel.distanthorizons.core.config.Config;
@@ -35,7 +34,6 @@ import com.seibel.distanthorizons.core.wrapperInterfaces.minecraft.IMinecraftRen
import com.seibel.distanthorizons.core.wrapperInterfaces.minecraft.IProfilerWrapper;
import com.seibel.distanthorizons.core.wrapperInterfaces.render.IMcLodRenderer;
import com.seibel.distanthorizons.core.wrapperInterfaces.render.IVertexBufferWrapper;
import net.minecraft.client.Minecraft;
import net.minecraft.resources.Identifier;
import org.lwjgl.opengl.GL32;
import org.lwjgl.system.MemoryUtil;
@@ -81,7 +79,7 @@ public class McLodRenderer implements IMcLodRenderer
private McLodRenderer()
{
this.vertexFormat = VertexFormat.builder()
.add("vPosition", DhVertexFormat.SHORT_POS)
.add("vPosition", DhVertexFormat.SHORT_XYZ_POS)
.add("meta", DhVertexFormat.META)
.add("vColor", DhVertexFormat.RGBA_UBYTE_COLOR)
.add("irisMaterial", DhVertexFormat.IRIS_MATERIAL)
@@ -339,7 +337,7 @@ public class McLodRenderer implements IMcLodRenderer
//renderPass.popDebugGroup();
// bind MC color texture
// bind MC Lightmap
{
LightMapWrapper lightMapWrapper = (LightMapWrapper) renderEventParam.lightmap;