Open Zylann opened 6 years ago
Update: discussed this a little with Reduz, and he plans to implement another general technique that could give good results as well (see https://github.com/godotengine/godot/issues/22048#issuecomment-421475081). The benefits will need to be profiled to see if the BFS cave culling technique is still better.
Now when a block is not visible, it is removed from world https://github.com/Zylann/godot_voxel/commit/badf3876c38485d2cdb7be9bbbc538f49062dbc1
Whats the current state of that issue?
@blockspacer it's still relevant, until we see results of future culling system. Removing from world was a workaround to only get rid of another source of overhead.
I would like to implement a BFS cave-culling algorithm, as explained here https://tomcc.github.io/2014/08/31/visibility-1.html
Doing it should be relatively simple and extremely efficient for this kind of voxel terrain, however part of its efficiency relies on having control over frustrum culling. Two alternatives:
1)
process
, however limiting active cameras to 1 and not benefiting from multithreaded renderer modeIf I don't do any of these, the only thing I can do is to turn visibility of blocks on/off constantly in
process
, while still having classic frustrum culling crunching hundreds of blocks for no reason (and being slow at this). On top of that, in Godot invisible meshes are also taken to frustrum culling anyways...I have no idea yet how that can be done without having to fork the entire engine in addition to developping a module, that sounds quite impractical. I'll probably give it a go later and see what the concrete requirements happen to be.