Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Visibility range takes the model aabb into acount (#15164)
# Objective I'm building a game where i generate a set of meshes where the transform is identity, and in each mesh the vertices are offset to where the model is. When adding visibility ranges to the models i noticed that they only switched when the distance to the origin changed over the threshold and all at the same time. ## Solution I believe that each mesh gets a Aabb generated for use with visibility testing. So we can use that aabb to calculate a more representative distance to the mesh. The code to transform the aabb is taken from the visibility sysyem. ## Testing I tested the changes locally in my project. Would you like me to write an example or a test somewhere? Is there any other code that uses the visibility range, that i should also update?
- Loading branch information