mirror of
https://github.com/GTNewHorizons/Angelica.git
synced 2026-11-18 03:25:17 +00:00
Compare commits
5
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
720aaca1b7 | ||
|
|
1e71b1c4d8 | ||
|
|
df4c423e93 | ||
|
|
78e0074e5a | ||
|
|
0350ea2cb6 |
No files matched your search
@@ -15,7 +15,7 @@
|
||||
|
||||
# Required Dependencies
|
||||
* [UniMixins](https://github.com/LegacyModdingMC/UniMixins/releases) >= 0.1.19
|
||||
* [GTNHLib](https://github.com/GTNewHorizons/GTNHLib/releases) >= 0.6.6
|
||||
* [GTNHLib](https://github.com/GTNewHorizons/GTNHLib/releases) >= 0.6.20
|
||||
* NOTE: Some mods are not required, but a specific version is required if present - see: `Permanent Incompatibilities` below.
|
||||
|
||||
# Known (temporary) Incompatibilities
|
||||
@@ -29,6 +29,7 @@
|
||||
* FalseTweaks - Not currently planned (Looking for volunteers) [Might work if you effectively disable most of the mod]
|
||||
* SmoothFont - Not currently planned (Looking for volunteers)
|
||||
* RPLE - Not currently planned (Looking for volunteers)
|
||||
* LiteLoader - Install [LiteloaderLoader](https://github.com/Midnight145/LiteloaderLoader)
|
||||
|
||||
# Permanent Incompatibilities
|
||||
* OptiFine [Disabled, won't fix]
|
||||
|
||||
+1
-1
@@ -61,7 +61,7 @@ dependencies {
|
||||
|
||||
// Iris Shaders
|
||||
compileOnly('org.jetbrains:annotations:26.0.2')
|
||||
api("com.github.GTNewHorizons:GTNHLib:0.6.13:dev")
|
||||
api("com.github.GTNewHorizons:GTNHLib:0.6.20:dev")
|
||||
shadowImplementation("org.anarres:jcpp:1.4.14") // Apache 2.0
|
||||
shadowImplementation("org.taumc:glsl-transformation-lib:0.2.0-4.g6b42bca") {
|
||||
exclude module: "antlr4" // we only want to shadow the runtime module
|
||||
|
||||
@@ -7,8 +7,9 @@ import com.gtnewhorizons.angelica.mixins.interfaces.FontRendererAccessor;
|
||||
import it.unimi.dsi.fastutil.chars.Char2ShortOpenHashMap;
|
||||
import it.unimi.dsi.fastutil.objects.ObjectArrayList;
|
||||
import jss.util.RandomXoshiro256StarStar;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.FontRenderer;
|
||||
import net.minecraft.client.renderer.texture.TextureManager;
|
||||
import net.minecraft.client.gui.ScaledResolution;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
@@ -150,7 +151,7 @@ public class BatchingFontRenderer {
|
||||
return idx;
|
||||
}
|
||||
|
||||
private void pushDrawCmd(int startIdx, int idxCount, ResourceLocation texture) {
|
||||
private void pushDrawCmd(int startIdx, int idxCount, ResourceLocation texture, boolean isUnicode) {
|
||||
if (!batchCommands.isEmpty()) {
|
||||
final FontDrawCmd lastCmd = batchCommands.get(batchCommands.size() - 1);
|
||||
final int prevEndVtx = lastCmd.startVtx + lastCmd.idxCount;
|
||||
@@ -166,7 +167,7 @@ public class BatchingFontRenderer {
|
||||
}
|
||||
}
|
||||
final FontDrawCmd cmd = batchCommandPool.pop();
|
||||
cmd.reset(startIdx, idxCount, texture);
|
||||
cmd.reset(startIdx, idxCount, texture, isUnicode);
|
||||
batchCommands.add(cmd);
|
||||
}
|
||||
|
||||
@@ -174,12 +175,14 @@ public class BatchingFontRenderer {
|
||||
|
||||
public int startVtx;
|
||||
public int idxCount;
|
||||
public boolean isUnicode;
|
||||
public ResourceLocation texture;
|
||||
|
||||
public void reset(int startVtx, int vtxCount, ResourceLocation texture) {
|
||||
public void reset(int startVtx, int vtxCount, ResourceLocation texture, boolean isUnicode) {
|
||||
this.startVtx = startVtx;
|
||||
this.idxCount = vtxCount;
|
||||
this.texture = texture;
|
||||
this.isUnicode = isUnicode;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -280,7 +283,21 @@ public class BatchingFontRenderer {
|
||||
}
|
||||
batchIndices.limit(cmd.startVtx + cmd.idxCount);
|
||||
batchIndices.position(cmd.startVtx);
|
||||
|
||||
Minecraft mc = Minecraft.getMinecraft();
|
||||
int scaleFactor = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight).getScaleFactor();
|
||||
boolean shouldApplyFilter = cmd.isUnicode && scaleFactor % 2 != 0;
|
||||
|
||||
if (shouldApplyFilter) {
|
||||
GLStateManager.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, GL11.GL_LINEAR);
|
||||
GLStateManager.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, GL11.GL_LINEAR);
|
||||
}
|
||||
GL11.glDrawElements(GL11.GL_TRIANGLES, batchIndices);
|
||||
|
||||
if (shouldApplyFilter) {
|
||||
GLStateManager.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MIN_FILTER, GL11.GL_NEAREST);
|
||||
GLStateManager.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_MAG_FILTER, GL11.GL_NEAREST);
|
||||
}
|
||||
}
|
||||
|
||||
GL11.glDisableClientState(GL11.GL_TEXTURE_COORD_ARRAY);
|
||||
@@ -367,7 +384,7 @@ public class BatchingFontRenderer {
|
||||
if (curUnderline && underlineStartX != underlineEndX) {
|
||||
final int ulIdx = idxWriterIndex;
|
||||
pushUntexRect(underlineStartX, underlineY, underlineEndX - underlineStartX, 1.0f, curColor);
|
||||
pushDrawCmd(ulIdx, 6, null);
|
||||
pushDrawCmd(ulIdx, 6, null, false);
|
||||
underlineStartX = underlineEndX;
|
||||
}
|
||||
if (curStrikethrough && strikethroughStartX != strikethroughEndX) {
|
||||
@@ -378,7 +395,7 @@ public class BatchingFontRenderer {
|
||||
strikethroughEndX - strikethroughStartX,
|
||||
1.0f,
|
||||
curColor);
|
||||
pushDrawCmd(ulIdx, 6, null);
|
||||
pushDrawCmd(ulIdx, 6, null, false);
|
||||
strikethroughStartX = strikethroughEndX;
|
||||
}
|
||||
|
||||
@@ -462,13 +479,13 @@ public class BatchingFontRenderer {
|
||||
final int endColumn = this.glyphWidth[chr] & 15;
|
||||
final float startColumnF = (float) startColumn;
|
||||
final float endColumnF = (float) (endColumn + 1);
|
||||
uStart = ((float) (chr % 16 * 16) + startColumnF) / 256.0f;
|
||||
vStart = ((float) ((chr & 255) / 16 * 16)) / 256.0f;
|
||||
uStart = ((float) (chr % 16 * 16) + startColumnF + 0.21f) / 256.0f;
|
||||
vStart = ((float) ((chr & 255) / 16 * 16) + 0.21f) / 256.0f;
|
||||
final float chrWidth = endColumnF - startColumnF - 0.02F;
|
||||
glyphW = chrWidth / 2.0f + 1.0f;
|
||||
xAdvance = (endColumnF - startColumnF) / 2.0F + 1.0F;
|
||||
uSz = chrWidth / 256.0f;
|
||||
vSz = 15.98f / 256.0f;
|
||||
uSz = (chrWidth - 0.42f) / 256.0f;
|
||||
vSz = (16.0f - 0.42f) / 256.0f;
|
||||
|
||||
} else {
|
||||
// Draw "ASCII" char
|
||||
@@ -556,7 +573,7 @@ public class BatchingFontRenderer {
|
||||
vtxCount += 4;
|
||||
}
|
||||
|
||||
pushDrawCmd(idxId, vtxCount / 2 * 3, texture);
|
||||
pushDrawCmd(idxId, vtxCount / 2 * 3, texture, chr > 255);
|
||||
curX += xAdvance + (curBold ? shadowOffset : 0.0f);
|
||||
underlineEndX = curX;
|
||||
strikethroughEndX = curX;
|
||||
@@ -565,7 +582,7 @@ public class BatchingFontRenderer {
|
||||
if (curUnderline && underlineStartX != underlineEndX) {
|
||||
final int ulIdx = idxWriterIndex;
|
||||
pushUntexRect(underlineStartX, underlineY, underlineEndX - underlineStartX, 1.0f, curColor);
|
||||
pushDrawCmd(ulIdx, 6, null);
|
||||
pushDrawCmd(ulIdx, 6, null, false);
|
||||
}
|
||||
if (curStrikethrough && strikethroughStartX != strikethroughEndX) {
|
||||
final int ulIdx = idxWriterIndex;
|
||||
@@ -575,7 +592,7 @@ public class BatchingFontRenderer {
|
||||
strikethroughEndX - strikethroughStartX,
|
||||
1.0f,
|
||||
curColor);
|
||||
pushDrawCmd(ulIdx, 6, null);
|
||||
pushDrawCmd(ulIdx, 6, null, false);
|
||||
}
|
||||
|
||||
} finally {
|
||||
|
||||
@@ -9,6 +9,8 @@ import java.io.File;
|
||||
import java.io.FileReader;
|
||||
import java.io.FileWriter;
|
||||
import java.io.PrintWriter;
|
||||
import java.util.EnumSet;
|
||||
import java.util.Set;
|
||||
|
||||
public class VideoSettings {
|
||||
private final File optionsFile;
|
||||
@@ -19,11 +21,12 @@ public class VideoSettings {
|
||||
|
||||
public void loadSettings() {
|
||||
try {
|
||||
if (!optionsFile.exists()) {
|
||||
if (!optionsFile.exists() && !optionsFile.createNewFile()) {
|
||||
return;
|
||||
}
|
||||
BufferedReader bufferedreader = new BufferedReader(new FileReader(optionsFile));
|
||||
String settingString;
|
||||
Set<Settings> loadedSettings = EnumSet.noneOf(Settings.class);
|
||||
|
||||
while((settingString = bufferedreader.readLine()) != null) {
|
||||
try {
|
||||
@@ -31,12 +34,19 @@ public class VideoSettings {
|
||||
Settings setting = Settings.valueOf(fragments[0]);
|
||||
setting.option.deserialize(fragments[1]);
|
||||
setting.applyChanges();
|
||||
loadedSettings.add(setting);
|
||||
} catch (Exception exception) {
|
||||
NotFine.logger.warn("Skipping bad option: " + settingString);
|
||||
}
|
||||
|
||||
}
|
||||
bufferedreader.close();
|
||||
|
||||
for (Settings setting : Settings.values()) {
|
||||
if (!loadedSettings.contains(setting)) {
|
||||
setting.applyChanges();
|
||||
}
|
||||
}
|
||||
} catch (Exception exception) {
|
||||
NotFine.logger.error("Failed to load options", exception);
|
||||
}
|
||||
|
||||
+2
-2
@@ -17,7 +17,7 @@ public class ChunkModelVertexTransformer extends AbstractVertexTransformer<Model
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
this.delegate.writeQuad(x + this.offset.x, y + this.offset.y, z + this.offset.z, color, u, v, light);
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
this.delegate.writeQuad(x + this.offset.x, y + this.offset.y, z + this.offset.z, color, u, v, light, shaderBlockId);
|
||||
}
|
||||
}
|
||||
+2
-1
@@ -12,6 +12,7 @@ public interface ModelVertexSink extends VertexSink {
|
||||
* @param u The u-texture of the vertex
|
||||
* @param v The y-texture of the vertex
|
||||
* @param light The packed light-map coordinates of the vertex
|
||||
* @param shaderBlockId The blockId to be passed to the shader
|
||||
*/
|
||||
void writeQuad(float x, float y, float z, int color, float u, float v, int light);
|
||||
void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId);
|
||||
}
|
||||
+1
-1
@@ -14,7 +14,7 @@ public class HFPModelVertexBufferWriterNio extends VertexBufferWriterNio impleme
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
this.writeQuadInternal(
|
||||
ModelVertexUtil.denormalizeVertexPositionFloatAsShort(x),
|
||||
ModelVertexUtil.denormalizeVertexPositionFloatAsShort(y),
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ public class HFPModelVertexBufferWriterUnsafe extends VertexBufferWriterUnsafe i
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
this.writeQuadInternal(
|
||||
ModelVertexUtil.denormalizeVertexPositionFloatAsShort(x),
|
||||
ModelVertexUtil.denormalizeVertexPositionFloatAsShort(y),
|
||||
|
||||
+1
-1
@@ -13,7 +13,7 @@ public class SFPModelVertexBufferWriterNio extends VertexBufferWriterNio impleme
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
int i = this.writeOffset;
|
||||
|
||||
ByteBuffer buffer = this.byteBuffer;
|
||||
|
||||
+1
-1
@@ -13,7 +13,7 @@ public class SFPModelVertexBufferWriterUnsafe extends VertexBufferWriterUnsafe i
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
long i = this.writePointer;
|
||||
|
||||
memPutFloat(i, x);
|
||||
|
||||
@@ -150,6 +150,7 @@ public class BlockRenderer {
|
||||
|
||||
final ModelQuadOrientation order = (useSodiumLight || this.useSeparateAo) ? ModelQuadOrientation.orient(light.br) : ModelQuadOrientation.NORMAL;
|
||||
|
||||
int shaderBlockId = quad.getShaderBlockId();
|
||||
for (int dstIndex = 0; dstIndex < 4; dstIndex++) {
|
||||
final int srcIndex = order.getVertexIndex(dstIndex);
|
||||
|
||||
@@ -173,7 +174,7 @@ public class BlockRenderer {
|
||||
final int lm = (useSeparateAo) ? ModelQuadUtil.mergeBakedLight(quad.getLight(srcIndex), light.lm[srcIndex]) :
|
||||
(useSodiumLight) ? light.lm[srcIndex] : quad.getLight(srcIndex);
|
||||
|
||||
sink.writeQuad(x, y, z, color, u, v, lm);
|
||||
sink.writeQuad(x, y, z, color, u, v, lm, shaderBlockId);
|
||||
}
|
||||
|
||||
final TextureAtlasSprite sprite = quad.rubidium$getSprite();
|
||||
|
||||
@@ -405,7 +405,7 @@ public class FluidRenderer {
|
||||
|
||||
int light = this.quadLightData.lm[vertexIdx];
|
||||
|
||||
sink.writeQuad(x, y, z, color, u, v, light);
|
||||
sink.writeQuad(x, y, z, color, u, v, light, -1);
|
||||
|
||||
vertexIdx += lightOrder;
|
||||
}
|
||||
|
||||
@@ -1,13 +1,18 @@
|
||||
package net.coderbot.iris;
|
||||
|
||||
import com.google.common.base.Throwables;
|
||||
import com.gtnewhorizon.gtnhlib.client.renderer.CapturingTessellator;
|
||||
import com.gtnewhorizon.gtnhlib.client.renderer.TessellatorManager;
|
||||
import com.gtnewhorizons.angelica.AngelicaMod;
|
||||
import com.gtnewhorizons.angelica.Tags;
|
||||
import com.gtnewhorizons.angelica.config.AngelicaConfig;
|
||||
import com.mojang.realmsclient.gui.ChatFormatting;
|
||||
import cpw.mods.fml.client.registry.ClientRegistry;
|
||||
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
|
||||
import cpw.mods.fml.common.gameevent.InputEvent;
|
||||
import it.unimi.dsi.fastutil.objects.Object2IntMap;
|
||||
import lombok.Getter;
|
||||
import net.coderbot.iris.block_rendering.BlockRenderingSettings;
|
||||
import net.coderbot.iris.config.IrisConfig;
|
||||
import net.coderbot.iris.gl.shader.StandardMacros;
|
||||
import net.coderbot.iris.gui.screen.ShaderPackScreen;
|
||||
@@ -24,7 +29,9 @@ import net.coderbot.iris.shaderpack.option.OptionSet;
|
||||
import net.coderbot.iris.shaderpack.option.Profile;
|
||||
import net.coderbot.iris.shaderpack.option.values.MutableOptionValues;
|
||||
import net.coderbot.iris.shaderpack.option.values.OptionValues;
|
||||
import net.coderbot.iris.sodium.block_context.BlockContextHolder;
|
||||
import net.coderbot.iris.texture.pbr.PBRTextureManager;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.GuiScreen;
|
||||
import net.minecraft.client.multiplayer.WorldClient;
|
||||
@@ -639,4 +646,36 @@ public class Iris {
|
||||
ClientRegistry.registerKeyBinding(toggleShadersKeybind);
|
||||
ClientRegistry.registerKeyBinding(shaderpackScreenKeybind);
|
||||
}
|
||||
|
||||
static BlockContextHolder contextHolder;
|
||||
|
||||
private static int getShaderMaterialOverrideId(Block block, int meta) {
|
||||
if (contextHolder == null) {
|
||||
final Object2IntMap<Block> blockMatches = BlockRenderingSettings.INSTANCE.getBlockMatches();
|
||||
if (blockMatches == null) {
|
||||
return -1;
|
||||
}
|
||||
contextHolder = new BlockContextHolder(blockMatches);
|
||||
|
||||
}
|
||||
contextHolder.set(block, (short) block.getRenderType());
|
||||
return contextHolder.blockId;
|
||||
}
|
||||
|
||||
public static void setShaderMaterialOverride(Block block, int meta) {
|
||||
if (!AngelicaConfig.enableIris)
|
||||
return;
|
||||
|
||||
int blockId = getShaderMaterialOverrideId(block, meta);
|
||||
|
||||
CapturingTessellator tess = (CapturingTessellator) TessellatorManager.get();
|
||||
tess.setShaderBlockId(blockId);
|
||||
}
|
||||
|
||||
public static void resetShaderMaterialOverride() {
|
||||
if (!AngelicaConfig.enableIris)
|
||||
return;
|
||||
CapturingTessellator tess = (CapturingTessellator) TessellatorManager.get();
|
||||
tess.setShaderBlockId(-1);
|
||||
}
|
||||
}
|
||||
+2
-2
@@ -30,7 +30,7 @@ public class XHFPModelVertexBufferWriterNio extends VertexBufferWriterNio implem
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
uSum += u;
|
||||
vSum += v;
|
||||
|
||||
@@ -42,7 +42,7 @@ public class XHFPModelVertexBufferWriterNio extends VertexBufferWriterNio implem
|
||||
ModelVertexUtil.denormalizeVertexTextureFloatAsShort(u),
|
||||
ModelVertexUtil.denormalizeVertexTextureFloatAsShort(v),
|
||||
light,
|
||||
contextHolder.blockId,
|
||||
shaderBlockId != -1 ? (short)shaderBlockId : contextHolder.blockId,
|
||||
contextHolder.renderType,
|
||||
ExtendedDataHelper.computeMidBlock(x, y, z, contextHolder.localPosX, contextHolder.localPosY, contextHolder.localPosZ)
|
||||
);
|
||||
|
||||
+2
-2
@@ -30,7 +30,7 @@ public class XHFPModelVertexBufferWriterUnsafe extends VertexBufferWriterUnsafe
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light) {
|
||||
public void writeQuad(float x, float y, float z, int color, float u, float v, int light, int shaderBlockId) {
|
||||
uSum += u;
|
||||
vSum += v;
|
||||
|
||||
@@ -42,7 +42,7 @@ public class XHFPModelVertexBufferWriterUnsafe extends VertexBufferWriterUnsafe
|
||||
ModelVertexUtil.denormalizeVertexTextureFloatAsShort(u),
|
||||
ModelVertexUtil.denormalizeVertexTextureFloatAsShort(v),
|
||||
light,
|
||||
contextHolder.blockId,
|
||||
shaderBlockId != -1 ? (short)shaderBlockId : contextHolder.blockId,
|
||||
contextHolder.renderType,
|
||||
ExtendedDataHelper.computeMidBlock(x, y, z, contextHolder.localPosX, contextHolder.localPosY, contextHolder.localPosZ)
|
||||
);
|
||||
|
||||
+9
-1
@@ -5,6 +5,7 @@ import lombok.Getter;
|
||||
import net.coderbot.iris.rendertarget.IRenderTargetExt;
|
||||
import net.minecraft.client.renderer.OpenGlHelper;
|
||||
import net.minecraft.client.shader.Framebuffer;
|
||||
import net.minecraftforge.client.MinecraftForgeClient;
|
||||
import org.lwjgl.opengl.GL11;
|
||||
import org.lwjgl.opengl.GL14;
|
||||
import org.lwjgl.opengl.GL30;
|
||||
@@ -81,8 +82,15 @@ public abstract class MixinFramebuffer implements IRenderTargetExt {
|
||||
GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_WRAP_S, GL11.GL_CLAMP);
|
||||
GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL11.GL_TEXTURE_WRAP_T, GL11.GL_CLAMP);
|
||||
GL11.glTexParameteri(GL11.GL_TEXTURE_2D, GL14.GL_TEXTURE_COMPARE_MODE, 0);
|
||||
GLStateManager.glTexImage2D(GL11.GL_TEXTURE_2D, 0, GL11.GL_DEPTH_COMPONENT, width, height, 0, GL11.GL_DEPTH_COMPONENT, GL11.GL_FLOAT, (IntBuffer) null);
|
||||
if (MinecraftForgeClient.getStencilBits() != 0) {
|
||||
GLStateManager.glTexImage2D(GL11.GL_TEXTURE_2D, 0, GL30.GL_DEPTH24_STENCIL8, width, height, 0, GL30.GL_DEPTH_STENCIL, GL30.GL_UNSIGNED_INT_24_8, (IntBuffer) null);
|
||||
} else {
|
||||
GLStateManager.glTexImage2D(GL11.GL_TEXTURE_2D, 0, GL11.GL_DEPTH_COMPONENT, width, height, 0, GL11.GL_DEPTH_COMPONENT, GL11.GL_FLOAT, (IntBuffer) null);
|
||||
}
|
||||
OpenGlHelper.func_153188_a/*glFramebufferTexture2D*/(GL30.GL_FRAMEBUFFER, GL30.GL_DEPTH_ATTACHMENT, GL11.GL_TEXTURE_2D, this.iris$depthTextureId, 0);
|
||||
if (MinecraftForgeClient.getStencilBits() != 0) {
|
||||
OpenGlHelper.func_153188_a/*glFramebufferTexture2D*/(GL30.GL_FRAMEBUFFER, GL30.GL_STENCIL_ATTACHMENT, GL11.GL_TEXTURE_2D, this.iris$depthTextureId, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user