@Environment(value=CLIENT) public class ChunkBuilder.BuiltChunk extends Object
Modifier and Type | Class and Description |
---|---|
(package private) class |
ChunkBuilder.BuiltChunk.RebuildTask |
(package private) class |
ChunkBuilder.BuiltChunk.SortTask |
(package private) class |
ChunkBuilder.BuiltChunk.Task |
Modifier and Type | Field and Description |
---|---|
private Set<BlockEntity> |
blockEntities |
Box |
boundingBox |
private Map<RenderLayer,VertexBuffer> |
buffers |
AtomicReference<ChunkBuilder.ChunkData> |
data |
private boolean |
needsImportantRebuild |
private boolean |
needsRebuild |
private BlockPos.Mutable[] |
neighborPositions |
private BlockPos.Mutable |
origin |
private int |
rebuildFrame |
private ChunkBuilder.BuiltChunk.RebuildTask |
rebuildTask |
private ChunkBuilder.BuiltChunk.SortTask |
sortTask |
Constructor and Description |
---|
BuiltChunk() |
Modifier and Type | Method and Description |
---|---|
private void |
beginBufferBuilding(BufferBuilder buffer) |
protected void |
cancel() |
void |
cancelRebuild() |
private void |
clear() |
ChunkBuilder.BuiltChunk.Task |
createRebuildTask() |
void |
delete() |
VertexBuffer |
getBuffer(RenderLayer layer) |
ChunkBuilder.ChunkData |
getData() |
BlockPos |
getNeighborPosition(Direction direction) |
BlockPos |
getOrigin() |
protected double |
getSquaredCameraDistance() |
private boolean |
isChunkNonEmpty(BlockPos pos) |
boolean |
needsImportantRebuild() |
boolean |
needsRebuild() |
void |
rebuild() |
void |
scheduleRebuild(boolean important) |
void |
scheduleRebuild(ChunkBuilder chunkRenderer) |
boolean |
scheduleSort(RenderLayer layer,
ChunkBuilder chunkRenderer) |
private void |
setNoCullingBlockEntities(Set<BlockEntity> noCullingBlockEntities) |
void |
setOrigin(int x,
int y,
int z) |
boolean |
setRebuildFrame(int frame) |
boolean |
shouldBuild() |
public final AtomicReference<ChunkBuilder.ChunkData> data
@Nullable private ChunkBuilder.BuiltChunk.RebuildTask rebuildTask
@Nullable private ChunkBuilder.BuiltChunk.SortTask sortTask
private final Set<BlockEntity> blockEntities
private final Map<RenderLayer,VertexBuffer> buffers
public Box boundingBox
private int rebuildFrame
private boolean needsRebuild
private final BlockPos.Mutable origin
private final BlockPos.Mutable[] neighborPositions
private boolean needsImportantRebuild
private boolean isChunkNonEmpty(BlockPos pos)
public boolean shouldBuild()
public boolean setRebuildFrame(int frame)
public VertexBuffer getBuffer(RenderLayer layer)
public void setOrigin(int x, int y, int z)
protected double getSquaredCameraDistance()
private void beginBufferBuilding(BufferBuilder buffer)
public ChunkBuilder.ChunkData getData()
private void clear()
public void delete()
public BlockPos getOrigin()
public void scheduleRebuild(boolean important)
public void cancelRebuild()
public boolean needsRebuild()
public boolean needsImportantRebuild()
public boolean scheduleSort(RenderLayer layer, ChunkBuilder chunkRenderer)
protected void cancel()
public ChunkBuilder.BuiltChunk.Task createRebuildTask()
public void scheduleRebuild(ChunkBuilder chunkRenderer)
private void setNoCullingBlockEntities(Set<BlockEntity> noCullingBlockEntities)
public void rebuild()