Search Unity

Occlusion Culling API?

Discussion in 'Scripting' started by TJHeuvel-net, Sep 3, 2015.

Thread Status:
Not open for further replies.
  1. TJHeuvel-net

    TJHeuvel-net

    Joined:
    Jul 31, 2012
    Posts:
    838
    For optimalisation purposes i'd like to disable objects when they are culled, though OnBecameVisible and OnBecameInvisible seem to be triggered only with Frustrum Culling, not Occlusion Culling.

    Is there a way to sample the occlusion system to know if an object is culled?
     
    dog_funtom likes this.
  2. TJHeuvel-net

    TJHeuvel-net

    Joined:
    Jul 31, 2012
    Posts:
    838
    I've hacked around it for now, it seems that OnWillRenderObject is affected by occlusion culling. Though a cleaner solution would be very much appreciated!
     
    nicg220 and dog_funtom like this.
  3. sewy

    sewy

    Joined:
    Oct 11, 2015
    Posts:
    150
    For our purpose, we would need to modify occlusion data (remove some static objects around camera from occlusion), so OC API would be great.
     
  4. MelvMay

    MelvMay

    Unity Technologies

    Joined:
    May 24, 2013
    Posts:
    11,459
    Please look at the dates of posts before posting.This is an 8 year old necropost. Feel free to create your own threads to discuss your needs.

    Community Code of Conduct (1i).
     
Thread Status:
Not open for further replies.