How to disable default camera culling

i noticed that when i go into wireframe mode and look at one corner of a large model the numbers of active mesh decrease meaning they have been camera culled but i would like to disable that because i don’t know what logic it’s using to hide the mesh. I would like to have control over how things hidden to prevent unnecessary computation that the default babylon engine has. If anyone know how the culling system, for example is it checking for mesh collisions to enable/disable mesh and if so how do i disable this so i can improve it for my custom culling method.

I don’t know why you would want to redo something the engine already does. Trust the engine, it handles things very well there.
Would you say that the engine is making unnecessary calculations and that you could do better by managing things yourself? Because if you found something wrong, you should propose a PR or report what you found wrong so that everyone can benefit from it.

1 Like

This page might be a good start if you want to try improving performances in camera culling.

If you have meshes you know you’ll never want to cull, you can set mesh.alwaysSelectAsActiveMesh = true

And while totally disabling the existing feature to improve it with a custom one seems a bit optimistic, you can start with scene._skipFrustumClipping = true; (no check, all meshes will be active), and toggle meshes.isVisible instead ? But like @Dad72 pointed, it seems unlikely to be worthy.

2 Likes