载入中...
搜索中...
未找到
GreedyMesher.h
浏览该文件的文档.
Greedy rectangle mesher for one 32³ dense voxel volume. Voxel storage: index = x + y*32 + z*32*32....
Definition GreedyMesher.h:33
static void meshFace(const uint8_t *voxels, FaceDir dir, std::vector< PackedRect > &out, const CubeTypeRegistry &types=CubeTypeRegistry::empty(), ChunkSampler sampler=nullptr, void *samplerUserData=nullptr, int chunkX=0, int chunkY=0, int chunkZ=0, std::vector< uint32_t > *aoOut=nullptr)
Mesh a single face direction into out (appended; caller may clear).
Definition GreedyMesher.cpp:160
static void meshChunk(const uint8_t *voxels, std::vector< PackedRect > outFaces[6], const CubeTypeRegistry &types=CubeTypeRegistry::empty(), ChunkSampler sampler=nullptr, void *samplerUserData=nullptr, int chunkX=0, int chunkY=0, int chunkZ=0, std::vector< uint32_t > aoOut[6]=nullptr)
Mesh all six faces. Clears and fills outFaces[6].
Definition GreedyMesher.cpp:254
方块类型定义:名字、各面图集纹理、方向性、组合声明。 方向性方块在注册时按 orientation 绕 Y 轴展开成多个"具体类型"变体, 每个变体持有旋转后的各面纹理;渲染端只消费纹理 id,不接触 ...
Definition Chunk.h:12
uint8_t(*)(void *userData, int chunkX, int chunkY, int chunkZ, int localX, int localY, int localZ) ChunkSampler
Optional out-of-chunk neighbor sampler for seam culling. Receives chunk coordinates plus the (possibl...
Definition GreedyMesher.h:19
FaceDir
Six axis-aligned face directions. Each chunk keeps a separate instance buffer per direction so camera...
Definition FaceDir.h:17