- Home /
Question by
ELudwig · Jun 18, 2016 at 05:41 AM ·
cameraphysicscustomocclusion culling
How do I get GameObjects seen by camera?
Good morning everyone :)
For several days I'm searching for a solution to get all GameObjects seen by a camera. I found this topic: http://answers.unity3d.com/questions/8003/how-can-i-know-if-a-gameobject-is-seen-by-a-partic.html
But in this case the GameObject itself have to inform the game, that it is seen. But with a few hundred or thousand objects this will kill the performance. I found out that I can use Physics.OverlapBox for this job.
The question is now: How can I use Physics.OverlapBox to get all GameObjects (or: Colliders) seen by a camera?
Thanks in advance :)
Kind regards Enrico Ludwig
Comment