-
Notifications
You must be signed in to change notification settings - Fork 289
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Concepts for supporting Occlusion Culling #790
Comments
cc @lojjic @dbuck your comments on Twitter are what led me to thinking through this a bit more - not sure if you have any further thoughts. Though rereading the tweet it sounds more like raycasting is used to determine more precise distances for screenspace error calculation over the bounding box calculations. Is that right? |
That would probably be smart 😉 but no, currently it's just a "downgrade if not seen" while still using bbox distance. I don't remember if we tried using the raycast distance - @dbuck do you recall? We did experiment briefly with webgl2 occlusion queries, but it gave false positives due to render order like you hinted at. |
Oh interesting! Good to know. If you have any more concrete details on the improvements (performance, number of tiles loaded / rendered, approach for determining when / how many raycasts to run, etc) or rough algorithm that would be great to know. Did you guys have to make changes to the core library to achieve this?
This is what I figured - good to have it confirmed. Occlusion queries don't sound like a viable solution in this case, then. |
The other issue when we were looking into it was that at the time, safari 15 wasn't yet out! And that was a LARGE chunk of our mobile users that couldn't use gl2 at that time. All to say, we didn't give it a ton of experimentation/scrutiny when the raycast based occlusion would serve for all of our users for a couple dozen raycasts/frame accumulated.
IIRC, We only used the raycast distances for the texture streaming system that was in use for the visible 3d-tiles to choose which resolution texture was needed. |
If a tile can't be seen because it is behind other geometry or not rendered because it is off screen / the tile geometry doesn't match the bounding box well then it's not worth refining the tile to the next layers. If a parent tile is already refined and then suddenly wouldn't be visible because the camera moved then the parents occlusion visibility can be inferred from child tiles, similar to frustum culling (though this may cause similar issues to the frustum culling approach due to parent tile sets being implicitly removed resulting in cyclic loading. See #741) (Child tiles may also not be visible while a parent tile is due to geometry differences, also potentially resulting in cyclic loading if not handled correctly).
Occlusion culling could be done in the following ways and added as a plugin - it shouldn't need to be synchronous:
The text was updated successfully, but these errors were encountered: