mirror of
https://github.com/GTNewHorizons/Angelica.git
synced 2026-11-25 06:34:27 +00:00
Use Separate AO & SmoothLightPipeline
This commit is contained in:
1 parent
bb52476d27
commit
88e4d2fd6c
8 files changed
+295
-36
No files matched your search
+74
-30
@@ -6,13 +6,20 @@ import com.gtnewhorizons.angelica.dynamiclights.IDynamicLightSource;
|
||||
import java.util.List;
|
||||
import com.gtnewhorizons.angelica.rendering.celeritas.iris.BlockRenderContext;
|
||||
import com.gtnewhorizons.angelica.rendering.celeritas.iris.IrisExtendedChunkVertexEncoder;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.ChunkColorWriter;
|
||||
import com.gtnewhorizons.angelica.rendering.celeritas.light.LightDataCache;
|
||||
import com.gtnewhorizons.angelica.rendering.celeritas.light.VanillaDiffuseProvider;
|
||||
import org.embeddedt.embeddium.impl.model.light.smooth.SmoothLightPipeline;
|
||||
import com.gtnewhorizons.angelica.rendering.celeritas.world.WorldSlice;
|
||||
import lombok.Getter;
|
||||
import me.jellysquid.mods.sodium.client.SodiumClientMod;
|
||||
import net.coderbot.iris.block_rendering.BlockRenderingSettings;
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.multiplayer.WorldClient;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.client.renderer.texture.TextureAtlasSprite;
|
||||
import net.minecraft.client.renderer.texture.TextureMap;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import org.embeddedt.embeddium.impl.model.light.data.QuadLightData;
|
||||
import org.embeddedt.embeddium.impl.model.quad.properties.ModelQuadFacing;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.RenderPassConfiguration;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.compile.ChunkBuildBuffers;
|
||||
@@ -26,20 +33,43 @@ import org.embeddedt.embeddium.impl.util.QuadUtil;
|
||||
public class AngelicaChunkBuildContext extends ChunkBuildContext {
|
||||
public static final int NUM_PASSES = 2;
|
||||
|
||||
private final TextureMap textureMap;
|
||||
private final TextureMapExtension textureAtlas;
|
||||
private final ChunkVertexEncoder.Vertex[] vertices = ChunkVertexEncoder.Vertex.uninitializedQuad();
|
||||
@Getter
|
||||
private final WorldSlice worldSlice;
|
||||
@Getter
|
||||
private final BlockRenderContext blockRenderContext = new BlockRenderContext();
|
||||
|
||||
/** Pre-filtered light sources for the current chunk being built. Null if dynamic lights disabled. */
|
||||
private List<IDynamicLightSource> chunkLightSources;
|
||||
private DynamicLights dynamicLightsInstance;
|
||||
|
||||
private final LightDataCache lightDataCache = new LightDataCache();
|
||||
private final SmoothLightPipeline smoothLightPipeline;
|
||||
private final QuadLightData quadLightData = new QuadLightData();
|
||||
private final VertexArrayQuadView quadView;
|
||||
private boolean lightPipelineReady = false;
|
||||
private int originX, originY, originZ;
|
||||
|
||||
public AngelicaChunkBuildContext(RenderPassConfiguration<?> renderPassConfiguration, WorldClient world) {
|
||||
super(renderPassConfiguration);
|
||||
this.textureMap = Minecraft.getMinecraft().getTextureMapBlocks();
|
||||
this.textureAtlas = (TextureMapExtension) Minecraft.getMinecraft().getTextureMapBlocks();
|
||||
this.worldSlice = new WorldSlice(world);
|
||||
this.smoothLightPipeline = new SmoothLightPipeline(lightDataCache, VanillaDiffuseProvider.INSTANCE, false);
|
||||
this.quadView = new VertexArrayQuadView(vertices);
|
||||
}
|
||||
|
||||
public void setupLightPipeline(int minBlockX, int minBlockY, int minBlockZ) {
|
||||
setupLightPipeline(worldSlice, minBlockX, minBlockY, minBlockZ);
|
||||
}
|
||||
|
||||
public void setupLightPipeline(IBlockAccess blockAccess, int minBlockX, int minBlockY, int minBlockZ) {
|
||||
this.originX = minBlockX;
|
||||
this.originY = minBlockY;
|
||||
this.originZ = minBlockZ;
|
||||
lightDataCache.setWorld(blockAccess);
|
||||
lightDataCache.reset(minBlockX, minBlockY, minBlockZ);
|
||||
smoothLightPipeline.reset();
|
||||
lightPipelineReady = true;
|
||||
}
|
||||
|
||||
public void setupDynamicLights(int chunkOriginX, int chunkOriginY, int chunkOriginZ) {
|
||||
@@ -52,18 +82,12 @@ public class AngelicaChunkBuildContext extends ChunkBuildContext {
|
||||
}
|
||||
}
|
||||
|
||||
public BlockRenderContext getBlockRenderContext() {
|
||||
return this.blockRenderContext;
|
||||
}
|
||||
|
||||
private Material selectMaterial(Material material, TextureAtlasSprite sprite) {
|
||||
if (sprite != null && sprite.getClass() == TextureAtlasSprite.class && !sprite.hasAnimationMetadata()) {
|
||||
final var transparencyLevel = ((SpriteExtension)sprite).celeritas$getTransparencyLevel();
|
||||
if (transparencyLevel == SpriteTransparencyLevel.OPAQUE && material == AngelicaRenderPassConfiguration.CUTOUT_MIPPED_MATERIAL) {
|
||||
// Downgrade to solid
|
||||
return AngelicaRenderPassConfiguration.SOLID_MATERIAL;
|
||||
} else if (material == AngelicaRenderPassConfiguration.TRANSLUCENT_MATERIAL && transparencyLevel != SpriteTransparencyLevel.TRANSLUCENT) {
|
||||
// Downgrade to cutout
|
||||
return AngelicaRenderPassConfiguration.CUTOUT_MIPPED_MATERIAL;
|
||||
}
|
||||
}
|
||||
@@ -71,8 +95,7 @@ public class AngelicaChunkBuildContext extends ChunkBuildContext {
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public void copyRawBuffer(int[] rawBuffer, int vertexCount, ChunkBuildBuffers buffers, Material material,
|
||||
int originX, int originY, int originZ) {
|
||||
public void copyRawBuffer(int[] rawBuffer, int vertexCount, ChunkBuildBuffers buffers, Material material) {
|
||||
if (vertexCount == 0) {
|
||||
return;
|
||||
}
|
||||
@@ -84,11 +107,10 @@ public class AngelicaChunkBuildContext extends ChunkBuildContext {
|
||||
}
|
||||
|
||||
final boolean hasDynamicLights = chunkLightSources != null && !chunkLightSources.isEmpty();
|
||||
|
||||
final var encoder = buffers.get(material).getEncoder();
|
||||
if (encoder instanceof IrisExtendedChunkVertexEncoder iris) {
|
||||
iris.setContext(blockRenderContext);
|
||||
}
|
||||
final boolean separateAo = BlockRenderingSettings.INSTANCE.shouldUseSeparateAo();
|
||||
final boolean sodiumAo = SodiumClientMod.options().quality.useSodiumAO;
|
||||
final boolean useAoCalculation = lightPipelineReady && (separateAo || sodiumAo);
|
||||
final ChunkColorWriter colorEncoder = separateAo ? ChunkColorWriter.SEPARATE_AO : ChunkColorWriter.EMBEDDIUM;
|
||||
|
||||
int ptr = 0;
|
||||
final int numQuads = vertexCount / 4;
|
||||
@@ -112,8 +134,42 @@ public class AngelicaChunkBuildContext extends ChunkBuildContext {
|
||||
vertex.color = rawBuffer[ptr++];
|
||||
vertex.vanillaNormal = rawBuffer[ptr++];
|
||||
vertex.light = rawBuffer[ptr++];
|
||||
}
|
||||
|
||||
if (hasDynamicLights) {
|
||||
final int trueNormal = QuadUtil.calculateNormal(vertices);
|
||||
final ModelQuadFacing facing = QuadUtil.findNormalFace(trueNormal);
|
||||
final TextureAtlasSprite sprite = this.textureAtlas.celeritas$findFromUV(uSum * 0.25f, vSum * 0.25f);
|
||||
|
||||
if (sprite != null && sprite.hasAnimationMetadata()) {
|
||||
animatedSprites.add(sprite);
|
||||
}
|
||||
|
||||
if (useAoCalculation) {
|
||||
final int blockX = blockRenderContext.localPosX;
|
||||
final int blockY = blockRenderContext.localPosY;
|
||||
final int blockZ = blockRenderContext.localPosZ;
|
||||
|
||||
quadView.setup(trueNormal, blockX, blockY, blockZ);
|
||||
final ModelQuadFacing lightFace = quadView.getLightFace();
|
||||
|
||||
smoothLightPipeline.calculate(quadView, originX + blockX, originY + blockY, originZ + blockZ, quadLightData, lightFace, lightFace, false, true);
|
||||
|
||||
for (int vIdx = 0; vIdx < 4; vIdx++) {
|
||||
final var vertex = vertices[vIdx];
|
||||
vertex.trueNormal = trueNormal;
|
||||
vertex.color = colorEncoder.writeColor(vertex.color, quadLightData.br[vIdx]);
|
||||
vertex.light = quadLightData.lm[vIdx];
|
||||
}
|
||||
} else {
|
||||
for (int vIdx = 0; vIdx < 4; vIdx++) {
|
||||
vertices[vIdx].trueNormal = trueNormal;
|
||||
}
|
||||
}
|
||||
|
||||
// Apply dynamic lights after AO calculation so they're not overwritten
|
||||
if (hasDynamicLights) {
|
||||
for (int vIdx = 0; vIdx < 4; vIdx++) {
|
||||
final var vertex = vertices[vIdx];
|
||||
final double dynamicLevel = dynamicLightsInstance.getDynamicLightLevelFromSources(
|
||||
originX + vertex.x, originY + vertex.y, originZ + vertex.z, chunkLightSources);
|
||||
if (dynamicLevel > 0) {
|
||||
@@ -122,18 +178,6 @@ public class AngelicaChunkBuildContext extends ChunkBuildContext {
|
||||
}
|
||||
}
|
||||
|
||||
final int trueNormal = QuadUtil.calculateNormal(vertices);
|
||||
for (int vIdx = 0; vIdx < 4; vIdx++) {
|
||||
vertices[vIdx].trueNormal = trueNormal;
|
||||
}
|
||||
|
||||
final ModelQuadFacing facing = QuadUtil.findNormalFace(trueNormal);
|
||||
final TextureAtlasSprite sprite = ((TextureMapExtension) textureMap).celeritas$findFromUV(uSum * 0.25f, vSum * 0.25f);
|
||||
|
||||
if (sprite != null && sprite.hasAnimationMetadata()) {
|
||||
animatedSprites.add(sprite);
|
||||
}
|
||||
|
||||
final Material correctMaterial = selectMaterial(material, sprite);
|
||||
final var builder = buffers.get(correctMaterial);
|
||||
|
||||
|
||||
+5
-4
@@ -218,10 +218,11 @@ public abstract class AngelicaChunkBuilderMeshingTask extends ChunkBuilderTask<C
|
||||
final var encoder = buffers.get(passMaterial).getEncoder();
|
||||
final ContextAwareChunkVertexEncoder contextEncoder = (encoder instanceof ContextAwareChunkVertexEncoder) ? (ContextAwareChunkVertexEncoder) encoder : null;
|
||||
|
||||
blockRenderContext.localPosX = x & 15;
|
||||
blockRenderContext.localPosY = y & 15;
|
||||
blockRenderContext.localPosZ = z & 15;
|
||||
|
||||
if (contextEncoder != null) {
|
||||
blockRenderContext.localPosX = x & 15;
|
||||
blockRenderContext.localPosY = y & 15;
|
||||
blockRenderContext.localPosZ = z & 15;
|
||||
final byte lightValue = (byte) block.getLightValue();
|
||||
if (isFluid) {
|
||||
contextEncoder.prepareToRenderFluid(blockRenderContext, block, lightValue);
|
||||
@@ -236,7 +237,7 @@ public abstract class AngelicaChunkBuilderMeshingTask extends ChunkBuilderTask<C
|
||||
block.canRenderInPass(pass);
|
||||
tessellator.startDrawingQuads();
|
||||
renderBlocks.renderBlockByRenderType(block, x, y, z);
|
||||
buildContext.copyRawBuffer(tessellator.rawBuffer, tessellator.vertexCount, buffers, passMaterial, originX, originY, originZ);
|
||||
buildContext.copyRawBuffer(tessellator.rawBuffer, tessellator.vertexCount, buffers, passMaterial);
|
||||
tessellator.reset();
|
||||
tessellator.isDrawing = false;
|
||||
|
||||
|
||||
+15
@@ -6,7 +6,10 @@ import net.minecraft.client.renderer.Tessellator;
|
||||
import net.minecraft.world.ChunkCache;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.RenderSection;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.compile.ChunkBuildContext;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.compile.ChunkBuildOutput;
|
||||
import org.embeddedt.embeddium.impl.util.position.SectionPos;
|
||||
import org.embeddedt.embeddium.impl.util.task.CancellationToken;
|
||||
import org.joml.Vector3d;
|
||||
|
||||
public class AngelicaMainThreadMeshingTask extends AngelicaChunkBuilderMeshingTask {
|
||||
@@ -30,6 +33,18 @@ public class AngelicaMainThreadMeshingTask extends AngelicaChunkBuilderMeshingTa
|
||||
this.blockAccess = new ChunkCache(world, minX - 1, minY - 1, minZ - 1, minX + 17, minY + 17, minZ + 17, 1);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ChunkBuildOutput execute(ChunkBuildContext context, CancellationToken cancellationToken) {
|
||||
final AngelicaChunkBuildContext buildContext = (AngelicaChunkBuildContext) context;
|
||||
|
||||
final int minX = this.render.getOriginX();
|
||||
final int minY = this.render.getOriginY();
|
||||
final int minZ = this.render.getOriginZ();
|
||||
buildContext.setupLightPipeline(blockAccess, minX, minY, minZ);
|
||||
|
||||
return super.execute(context, cancellationToken);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected Tessellator getTessellator() {
|
||||
return Tessellator.instance;
|
||||
|
||||
+118
@@ -0,0 +1,118 @@
|
||||
package com.gtnewhorizons.angelica.rendering.celeritas;
|
||||
|
||||
import org.embeddedt.embeddium.api.util.NormI8;
|
||||
import org.embeddedt.embeddium.impl.model.quad.ModelQuadView;
|
||||
import org.embeddedt.embeddium.impl.model.quad.properties.ModelQuadFacing;
|
||||
import org.embeddedt.embeddium.impl.model.quad.properties.ModelQuadFlags;
|
||||
import org.embeddedt.embeddium.impl.render.chunk.vertex.format.ChunkVertexEncoder;
|
||||
import org.embeddedt.embeddium.impl.util.QuadUtil;
|
||||
|
||||
public class VertexArrayQuadView implements ModelQuadView {
|
||||
private final ChunkVertexEncoder.Vertex[] vertices;
|
||||
private int trueNormal;
|
||||
private int blockX, blockY, blockZ;
|
||||
private ModelQuadFacing lightFace;
|
||||
|
||||
public VertexArrayQuadView(ChunkVertexEncoder.Vertex[] vertices) {
|
||||
this.vertices = vertices;
|
||||
}
|
||||
|
||||
public void setup(int trueNormal, int blockX, int blockY, int blockZ) {
|
||||
this.trueNormal = trueNormal;
|
||||
this.blockX = blockX;
|
||||
this.blockY = blockY;
|
||||
this.blockZ = blockZ;
|
||||
this.lightFace = null; // Reset cached lightFace
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getX(int idx) {
|
||||
return vertices[idx].x - blockX;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getY(int idx) {
|
||||
return vertices[idx].y - blockY;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getZ(int idx) {
|
||||
return vertices[idx].z - blockZ;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getColor(int idx) {
|
||||
return vertices[idx].color;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getTexU(int idx) {
|
||||
return vertices[idx].u;
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getTexV(int idx) {
|
||||
return vertices[idx].v;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getLight(int idx) {
|
||||
return vertices[idx].light;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getFlags() {
|
||||
return ModelQuadFlags.getQuadFlags(this, getLightFace());
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getColorIndex() {
|
||||
return -1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object celeritas$getSprite() {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelQuadFacing getLightFace() {
|
||||
if (lightFace == null) {
|
||||
lightFace = computeLightFace(trueNormal);
|
||||
}
|
||||
return lightFace;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ModelQuadFacing getNormalFace() {
|
||||
return QuadUtil.findNormalFace(trueNormal);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getForgeNormal(int idx) {
|
||||
return vertices[idx].vanillaNormal;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getComputedFaceNormal() {
|
||||
return trueNormal;
|
||||
}
|
||||
|
||||
private static ModelQuadFacing computeLightFace(int normal) {
|
||||
final float nx = NormI8.unpackX(normal);
|
||||
final float ny = NormI8.unpackY(normal);
|
||||
final float nz = NormI8.unpackZ(normal);
|
||||
|
||||
final float absX = Math.abs(nx);
|
||||
final float absY = Math.abs(ny);
|
||||
final float absZ = Math.abs(nz);
|
||||
|
||||
if (absY >= absX && absY >= absZ) {
|
||||
return ny >= 0 ? ModelQuadFacing.POS_Y : ModelQuadFacing.NEG_Y;
|
||||
} else if (absX >= absZ) {
|
||||
return nx >= 0 ? ModelQuadFacing.POS_X : ModelQuadFacing.NEG_X;
|
||||
} else {
|
||||
return nz >= 0 ? ModelQuadFacing.POS_Z : ModelQuadFacing.NEG_Z;
|
||||
}
|
||||
}
|
||||
}
|
||||
+43
@@ -0,0 +1,43 @@
|
||||
package com.gtnewhorizons.angelica.rendering.celeritas.light;
|
||||
|
||||
import lombok.Setter;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import org.embeddedt.embeddium.impl.model.light.data.LightDataAccess;
|
||||
|
||||
@Setter
|
||||
public class LightDataCache extends LightDataAccess {
|
||||
private IBlockAccess world;
|
||||
|
||||
@Override
|
||||
protected int compute(int x, int y, int z) {
|
||||
final IBlockAccess world = this.world;
|
||||
final Block block = world.getBlock(x, y, z);
|
||||
|
||||
final boolean fo = block.isOpaqueCube();
|
||||
final boolean fc = block.isNormalCube();
|
||||
final int lu = block.getLightValue(world, x, y, z);
|
||||
|
||||
// Optimize: skip light calculation for opaque blocks with no luminance
|
||||
final int bl, sl;
|
||||
if (fo && lu == 0) {
|
||||
bl = 0;
|
||||
sl = 0;
|
||||
} else {
|
||||
final int packed = world.getLightBrightnessForSkyBlocks(x, y, z, 0);
|
||||
bl = (packed >> 4) & 0xF;
|
||||
sl = (packed >> 20) & 0xF;
|
||||
}
|
||||
|
||||
// AO value - blocks that emit light don't contribute to AO
|
||||
final float ao = lu == 0 ? block.getAmbientOcclusionLightValue() : 1.0f;
|
||||
|
||||
// Opacity check - true if block is view-blocking (solid blocks)
|
||||
final boolean op = block.getMaterial().isOpaque() && block.getLightOpacity() > 0;
|
||||
|
||||
// Emissive check - full bright if lightmap coords would be max (15, 15)
|
||||
final boolean em = lu == 15;
|
||||
|
||||
return packFC(fc) | packFO(fo) | packOP(op) | packEM(em) | packAO(ao) | packLU(lu) | packSL(sl) | packBL(bl);
|
||||
}
|
||||
}
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
package com.gtnewhorizons.angelica.rendering.celeritas.light;
|
||||
|
||||
import org.embeddedt.embeddium.impl.model.light.DiffuseProvider;
|
||||
import org.embeddedt.embeddium.impl.model.quad.properties.ModelQuadFacing;
|
||||
|
||||
public enum VanillaDiffuseProvider implements DiffuseProvider {
|
||||
INSTANCE;
|
||||
|
||||
private static final float DOWN = 0.5f; // NEG_Y
|
||||
private static final float UP = 1.0f; // POS_Y
|
||||
private static final float NORTH_SOUTH = 0.8f; // NEG_Z, POS_Z
|
||||
private static final float EAST_WEST = 0.6f; // NEG_X, POS_X
|
||||
|
||||
@Override
|
||||
public float getDiffuse(float normalX, float normalY, float normalZ, boolean shade) {
|
||||
if (!shade) {
|
||||
return 1.0f;
|
||||
}
|
||||
return Math.min(normalX * normalX * EAST_WEST + normalY * normalY * (normalY >= 0 ? UP : DOWN) + normalZ * normalZ * NORTH_SOUTH, 1.0f);
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getDiffuse(ModelQuadFacing lightFace, boolean shade) {
|
||||
if (!shade) {
|
||||
return 1.0f;
|
||||
}
|
||||
return switch (lightFace) {
|
||||
case NEG_Y -> DOWN;
|
||||
case POS_Y -> UP;
|
||||
case NEG_Z, POS_Z -> NORTH_SOUTH;
|
||||
case NEG_X, POS_X -> EAST_WEST;
|
||||
case UNASSIGNED -> 1.0f;
|
||||
};
|
||||
}
|
||||
}
|
||||
+4
-1
@@ -39,7 +39,8 @@ public class ThreadedAngelicaChunkBuilderMeshingTask extends AngelicaChunkBuilde
|
||||
|
||||
@Override
|
||||
public ChunkBuildOutput execute(ChunkBuildContext context, CancellationToken cancellationToken) {
|
||||
initBlockAccess((AngelicaChunkBuildContext) context);
|
||||
final AngelicaChunkBuildContext buildContext = (AngelicaChunkBuildContext) context;
|
||||
initBlockAccess(buildContext);
|
||||
return super.execute(context, cancellationToken);
|
||||
}
|
||||
|
||||
@@ -54,12 +55,14 @@ public class ThreadedAngelicaChunkBuilderMeshingTask extends AngelicaChunkBuilde
|
||||
this.blockAccess = worldSlice;
|
||||
this.biomeColorCache = new SmoothBiomeColorCache(worldSlice);
|
||||
this.biomeColorCache.update(new SectionPos(this.render.getChunkX(), this.render.getChunkY(), this.render.getChunkZ()));
|
||||
buildContext.setupLightPipeline(minX, minY, minZ);
|
||||
} else {
|
||||
// Fallback: direct world access (main thread only)
|
||||
final var world = Minecraft.getMinecraft().theWorld;
|
||||
this.biomeColorCache = ((WorldClientExtension) world).celeritas$getSmoothBiomeColorCache();
|
||||
this.biomeColorCache.update(new SectionPos(this.render.getChunkX(), this.render.getChunkY(), this.render.getChunkZ()));
|
||||
this.blockAccess = new ChunkCache(world, minX - 1, minY - 1, minZ - 1, minX + 17, minY + 17, minZ + 17, 1);
|
||||
buildContext.setupLightPipeline(this.blockAccess, minX, minY, minZ);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user