starandserpent / java-TerraServer

Terra - Voxel octree of chunks, made for Rituals of the old
MIT License
18 stars 2 forks source link

Test poly count with hidden face culling on/off #48

Closed Pilvinen closed 5 years ago

Pilvinen commented 5 years ago

I have a working theory that the poly count would actually be lower with hidden face culling disabled because it's interfering with greedy meshing.

But it's not certain, so we should test it and see what kind of poly counts we get.

Example:

https://i.snag.gy/XGk06F.jpg Above is a plane made out of dirt blocks. Greedy meshed nicely.

https://i.snag.gy/4k8d7Z.jpg Above is the same plane of dirt blocks with the exception of one grass block placed on top of it. In normal greedy meshing it should not affect the outcome, but since we are actually removing the hidden faces under it -> it's interfering with the greedy mesher and creating more polys than are being removed.

On top of that removing the faces in the first place takes extra processing and it's currently doubtful that the gains (or losses?) are worth it.

Therefore we need to compare polycount and generation time with hidden face culling enabled and disabled.

Pilvinen commented 5 years ago

21 104 triangles with hidden face culling enabled.

Pawlost commented 5 years ago

Disabling hidden faces culling only for top layer increased triangles to 24 992