Closed MCArth closed 1 year ago
Hi, thanks a ton for checking this!
The transparency thing is something I forgot about, I've pushed a fix that ought to resolve it. I'll have a look at the performance issue now.
By the way, if you find multiple bugs do feel free to submit multiple separate issues, so they can track independently etc. Thanks as always!
Out of interest, what's the surface area usage of noa in your game - do you use most of it? are there any notable parts you don't use? (e.g. alpha-tested/blended blocks like here or perhaps some other features)
If there are I can be more careful pulling in changes that might affect them in the future
About the perf issue, I think all that's happening is the amount of meshing going on. You're returning non-opaque voxels (the cloud id) all throughout the terrain, so the engine is meshing voxel faces around them even if the non-opaque voxel is deep underground. (noa doesn't currently do any kind of line-of-sight checks when meshing)
I think what you probably want to do is assign random voxel IDs only at the surface level, and but return only solid voxels below that.
About surface area usage: I'm using almost everything, but transparent terrain blocks are one exception. Getting them to compose correctly even after chunking is a general problem I haven't had time to look closely at...
That makes sense, thanks for checking
Hi, I've been doing more testing and found an incredibly slow case meshing case with non-opaque blocks
To make the stress a bit more stressy, I modified the worldgen:
It seems likely the meshing functions are being de-opted somehow (if you remove the cloud opaque: false, this doesn't happen)
R.e. the alpha block textures not working, replace terrain_atlas with the below and uncomment the seethrough material above, including it in the worldgen - you'll see the middle of the block should be transparent but is black
R.e. #183 I'll see if I can get a repro in examples