Jump to content

Is a node/volume visible?


photo

Recommended Posts

Posted

Hello,

We have multiple nodes with some heavy components inside (with render to texture, etc). Is it possible, in the update call of these components, to check if the node they are modifying is visible at all (or was visible recently)? Is there any way to use a surface LOD visibility to check if the surface is actually significant/visible?

Posted

Hi Stephane,

There is a method called isVisibleCamera from the Object class that seems to do what you need: https://developer.unigine.com/en/docs/2.19.1/api/library/objects/class.object?rlang=cpp#isVisibleCamera_int

It's quite fast so you can use it without any worries. Unless you need to check thousands of objects per frame :)

Thanks!

  • Thanks 1

How to submit a good bug report
---
FTP server for test scenes and user uploads:

×
×
  • Create New...