3#include "mc/_HeaderOutputPredefine.h"
6#include "mc/client/renderer/block/BakedBlockLightType.h"
7#include "mc/client/renderer/chunks/RenderChunkPerformanceTrackingData.h"
8#include "mc/deps/game_refs/WeakRef.h"
9#include "mc/deps/minecraft_renderer/game/RangeIndices.h"
10#include "mc/world/level/block/BlockRenderLayer.h"
11#include "mc/world/level/chunk/ChunkSourceViewGenerateMode.h"
12#include "mc/world/phys/AABB.h"
36namespace mce {
class Mesh; }
45 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::ChunkViewSource>> mLocalSource;
46 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::BlockTessellator>> mBlockTessellator;
47 ::ll::TypedStorage<1, 1, bool> mAllDark;
48 ::ll::TypedStorage<1, 1, bool> mSkyLit;
49 ::ll::TypedStorage<1, 1, bool> mBlendCanRenderAsOpaque;
50 ::ll::TypedStorage<4, 4, float> mAverageSkyLight;
51 ::ll::TypedStorage<8, 168, ::std::array<::std::vector<::RenderChunkQuadInfo>, 7>> mFaceMetadata;
52 ::ll::TypedStorage<4, 176, ::std::array<::RangeIndices, 22>> mRenderLayerRanges;
53 ::ll::TypedStorage<8, 8, ::std::vector<::BlockQueueEntry>*> mQueues;
54 ::ll::TypedStorage<8, 8, ::std::vector<::BlockQueueEntry>*> mSimpleOpaqueBlockQueue;
55 ::ll::TypedStorage<8, 176, uint64[22]> mQueueIndexCounts;
56 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::Tessellator>> mOwnedTessellator;
57 ::ll::TypedStorage<8, 16, ::std::shared_ptr<::ClientBlockPipeline::MaterialRepository>> mMaterialRepository;
58 ::ll::TypedStorage<8, 16, ::std::weak_ptr<::RuntimeLocalLightingConfig const>> mLocalLightingConfig;
59 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::ClientBlockPipeline::BlockTessellatorPipeline>> mPipelineTessellator;
60 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::ClientBlockPipeline::Description>> mPipelineDescription;
61 ::ll::TypedStorage<8, 8, ::Tessellator&> mTessellator;
62 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::mce::Mesh>> mBuiltMesh;
63 ::ll::TypedStorage<8, 8, ::std::unique_ptr<::mce::MeshData>> mMeshData;
64 ::ll::TypedStorage<1, 1, bool> mGUIRendering;
65 ::ll::TypedStorage<4, 24, ::AABB> mBuildBoundingBox;
66 ::ll::TypedStorage<1, 1, bool> mUseNewTessellationPipeline;
67 ::ll::TypedStorage<1, 1, bool> mTextureShiftsEnabled;
68 ::ll::TypedStorage<8, 16, ::std::weak_ptr<::IRenderChunkGarbage>> mRenderChunkGarbage;
69 ::ll::TypedStorage<8, 16, ::WeakRef<::RenderChunkCoordinator>> mRenderChunkCoordinator;
74 RenderChunkBuilder& operator=(RenderChunkBuilder
const&);
75 RenderChunkBuilder(RenderChunkBuilder
const&);
81 MCAPI RenderChunkBuilder(
82 ::std::shared_ptr<::ClientBlockPipeline::MaterialRepository>
const& materialRepository,
83 ::ChunkSource& mainSource,
84 ::Tessellator& tessellator,
85 ::WeakRef<::RenderChunkCoordinator> coordinator
88 MCAPI RenderChunkBuilder(
89 ::std::shared_ptr<::ClientBlockPipeline::MaterialRepository>
const& materialRepository,
90 ::ChunkSource& mainSource,
91 ::Tessellator& tessellator,
92 ::std::weak_ptr<::IRenderChunkGarbage> garbage
95 MCAPI RenderChunkBuilder(
96 ::MinecraftGameplayGraphicsResources& minecraftGameplayGraphicsResources,
97 ::ClientBlockPipeline::TessellatorContext& pipelineTessellatorContext,
98 ::ChunkSource& mainSource,
99 ::WeakRef<::RenderChunkCoordinator> coordinator
102 MCAPI
void _buildRanges(::RenderChunkPerformanceTrackingData::RenderChunkBuildDetails&);
104 MCAPI
void _overrideStaticBlockLighting(
105 ::BlockSource& region,
106 ::SubChunkPos
const& subChunkPos,
107 ::AirAndSimpleBlockBits
const& airAndSimpleBlocks
110 MCAPI
bool _sortBlocks(
111 ::BlockSource& region,
112 ::RenderChunkGeometry& renderChunkGeometry,
113 bool airAndSimpleBlocks,
114 ::AirAndSimpleBlockBits&,
115 ::RenderChunkPerformanceTrackingData::RenderChunkBuildDetails&
118 MCAPI
bool _tessellateNewPipeline(
119 ::RenderChunkGeometry& renderChunkGeometry,
121 ::RenderChunkPerformanceTrackingData::RenderChunkBuildDetails&
124 MCAPI
bool _tessellateQueues(
125 ::RenderChunkGeometry& renderChunkGeometry,
126 ::BlockSource& region,
127 ::AirAndSimpleBlockBits& airAndSimpleBlocks,
128 ::RenderChunkPerformanceTrackingData::RenderChunkBuildDetails&
131 MCAPI
void _updateFacesMetadata();
133 MCAPI ::mce::MeshData acquireMeshData();
135 MCAPI
void applyBuildBoundingBox(::AABB
const& buildBoundingBox);
138 ::RenderChunkGeometry& renderChunkGeometry,
140 ::BakedBlockLightType forExport,
141 bool lightingModelCapabilities,
142 ::mce::framebuilder::FrameLightingModelCapabilities
const&
145 MCAPI
void prepareWorldData(::BlockPos
const& pos, ::ChunkSourceViewGenerateMode viewMoveMode);
147 MCAPI
void setGUIRendering(
bool guiRendering);
149 MCAPI ~RenderChunkBuilder();
155 MCAPI
static bool checkAndSetSimpleBlockInfo(
156 ::BlockRenderLayer renderLayer,
157 ::Block
const& block,
158 uint64 blockBitsetIndex,
159 ::AirAndSimpleBlockBits& airAndSimpleBlocks
162 MCAPI
static void checkNeighborBlockIsAirOrSimpleBlock(
163 ::Block
const& block,
164 uint64 blockBitsetIndex,
165 ::AirAndSimpleBlockBits& airAndSimpleBlocks
173 ::std::shared_ptr<::ClientBlockPipeline::MaterialRepository>
const& materialRepository,
174 ::ChunkSource& mainSource,
175 ::Tessellator& tessellator,
176 ::WeakRef<::RenderChunkCoordinator> coordinator
180 ::std::shared_ptr<::ClientBlockPipeline::MaterialRepository>
const& materialRepository,
181 ::ChunkSource& mainSource,
182 ::Tessellator& tessellator,
183 ::std::weak_ptr<::IRenderChunkGarbage> garbage
187 ::MinecraftGameplayGraphicsResources& minecraftGameplayGraphicsResources,
188 ::ClientBlockPipeline::TessellatorContext& pipelineTessellatorContext,
189 ::ChunkSource& mainSource,
190 ::WeakRef<::RenderChunkCoordinator> coordinator
Definition BlockSource.h:73
Definition BlockTessellator.h:5
Definition ChunkSource.h:37
Definition ChunkViewSource.h:23
Definition BlockTessellatorPipeline.h:7
Definition Description.h:7
Definition MaterialRepository.h:7
Definition TessellatorContext.h:7
Definition IRenderChunkGarbage.h:5
Definition MinecraftGameplayGraphicsResources.h:5
Definition RenderChunkBuilder.h:5
Definition RenderChunkCoordinator.h:5
Definition RenderChunkGeometry.h:5
Definition RuntimeLocalLightingConfig.h:5
Definition SubChunkPos.h:5
Definition Tessellator.h:5
Definition AirAndSimpleBlockBits.h:5
Definition BlockQueueEntry.h:5
Definition RenderChunkQuadInfo.h:5
Definition FrameLightingModelCapabilities.h:7