Skip to content
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

Invalid visibility data #4

Open
AntonPetrov83 opened this issue Jul 29, 2022 · 0 comments
Open

Invalid visibility data #4

AntonPetrov83 opened this issue Jul 29, 2022 · 0 comments

Comments

@AntonPetrov83
Copy link

AntonPetrov83 commented Jul 29, 2022

Hi!

From the documentation:

public bool IsVisible(int index);

Note that this method uses the most recently computed visibility states. Visibility is updated immediately before rendering, so using this method in Update/LateUpdate will provide results based on calculations from the previous frame.

IndexOf and all its usages, including IsVisible return invalid results because of indices mismatch between current m_Targets list and CullingGroup latest culling results on the frame when m_Targets is being modified.

Consider using EraseSwapBack group of methods.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant