mirror of
https://github.com/GayPizzaSpecifications/voxelotl-engine.git
synced 2025-08-03 05:10:57 +00:00
implement parallel chunk mesh building
This commit is contained in:
@ -1,7 +1,5 @@
|
||||
struct ChunkMeshBuilder {
|
||||
public static func build(world: World, chunkID: SIMD3<Int>) -> Mesh<VertexPositionNormalColorTexcoord, UInt16> {
|
||||
guard let chunk = world.getChunk(id: chunkID) else { return .empty }
|
||||
|
||||
public static func build(world: World, chunk: Chunk) -> Mesh<VertexPositionNormalColorTexcoord, UInt16> {
|
||||
var vertices = [VertexPositionNormalColorTexcoord]()
|
||||
var indices = [UInt16]()
|
||||
chunk.forEach { block, position in
|
||||
|
Reference in New Issue
Block a user