diff --git a/src/main/java/net/coderbot/iris/pipeline/FixedFunctionWorldRenderingPipeline.java b/src/main/java/net/coderbot/iris/pipeline/FixedFunctionWorldRenderingPipeline.java index fbb0c03e8f..5526a63a9f 100644 --- a/src/main/java/net/coderbot/iris/pipeline/FixedFunctionWorldRenderingPipeline.java +++ b/src/main/java/net/coderbot/iris/pipeline/FixedFunctionWorldRenderingPipeline.java @@ -19,6 +19,7 @@ public FixedFunctionWorldRenderingPipeline() { BlockRenderingSettings.INSTANCE.setUseSeparateAo(false); BlockRenderingSettings.INSTANCE.setAmbientOcclusionLevel(1.0f); BlockRenderingSettings.INSTANCE.setUseExtendedVertexFormat(false); + BlockRenderingSettings.INSTANCE.setBlockTypeIds(null); } @Override diff --git a/src/main/java/net/coderbot/iris/rendertarget/DepthTexture.java b/src/main/java/net/coderbot/iris/rendertarget/DepthTexture.java index acb8c19747..bc1bbdf464 100644 --- a/src/main/java/net/coderbot/iris/rendertarget/DepthTexture.java +++ b/src/main/java/net/coderbot/iris/rendertarget/DepthTexture.java @@ -6,6 +6,7 @@ import net.coderbot.iris.gl.IrisRenderSystem; import net.coderbot.iris.gl.framebuffer.GlFramebuffer; import net.coderbot.iris.gl.texture.DepthBufferFormat; +import net.minecraft.client.Minecraft; import org.lwjgl.opengl.GL11C; import org.lwjgl.opengl.GL13C; import org.lwjgl.opengl.GL20C; @@ -31,8 +32,9 @@ void resize(int width, int height, GlFramebuffer copyTexture, DepthBufferFormat copyTexture.bindAsReadBuffer(); IrisRenderSystem.copyTexImage2D(GL20C.GL_TEXTURE_2D, 0, format.getGlInternalFormat(), 0, 0, width, height, 0); } else { - GlStateManager._texImage2D(GL11C.GL_TEXTURE_2D, 0, format.getGlInternalFormat(), width, height, 0, - format.getGlType(), format.getGlFormat(), null); + // NB: This isn't correct, but it's much better than garbage data being written to shadowtex0. + Minecraft.getInstance().getMainRenderTarget().bindWrite(false); + IrisRenderSystem.copyTexImage2D(GL20C.GL_TEXTURE_2D, 0, format.getGlInternalFormat(), 0, 0, width, height, 0); } GlStateManager._bindTexture(0);