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

Running no-threads web export blanks screen once 1000 objects are visible in scene due to threaded culling being incorrectly used #88192

Closed
JyveAFK opened this issue Feb 11, 2024 · 2 comments · Fixed by #99416

Comments

@JyveAFK
Copy link

JyveAFK commented Feb 11, 2024

Tested versions

v4.3.dev3.official[36e943b]

System information

Godot v4.3.dev3 - Windows 10.0.19045 - GLES3 (Compatibility) - NVIDIA GeForce GTX 1070 (NVIDIA; 31.0.15.2849) - Intel(R) Core(TM) i7-8700 CPU @ 3.20GHz (12 Threads)

Issue description

When running a scene with 1000 objects in a scene in a webexport (both on a server and from the editor), the screen blanks and nothing is visible apart from the background colour of the scene.
With 999 objects, it works;
image
With 1000 objects, it blanks out everything that was in the scene already.

image

Steps to reproduce

Add 1000 objects to a scene. Run it normally, it'll work. Add a 'webexport', turn off threading in the export, and hit 'run in browser' and the project exhibits the problem.
image

Minimal reproduction project (MRP)

WebExport1000.zip

@clayjohn
Copy link
Member

Perhaps this is connected to rendering/limits/spatial_indexer/threaded_cull_minimum_instances? Can you try increasing that limit and seeing what happens?

Or conversely lowering the limit and seeing if you can reproduce the issue with fewer objects?

@JyveAFK
Copy link
Author

JyveAFK commented Feb 11, 2024

That was exactly it. Bumping it up, gets it working, lowering it down to a 100, stops it working past 99 objects in a scene. Thank you, hadn't seen that setting/understood what it was used for.

Is this something I can set in the code/something for a scene property to get it to roughly have an idea when it needs to worry about culling, or just be careful for webexports and check/set it a few % above the amount of objects you think you'll need in the scene? Is there a way around this, or am I doing something wrong.

Also tested, when it goes too high and everything disappears, removing nodes WILL make everything re-appear again. I thought everything in the scene had disappeared, but it was just waiting to get down below that number to display again.

Thanks for the heads up on where to look for this setting. I'll make note to check on node counts in a scene before webexports.

@Calinou Calinou changed the title Running WebExport blanks screen once 1000 objects in scene added. Running web export blanks screen once 1000 objects are visible in scene due to threaded culling Feb 12, 2024
@Calinou Calinou changed the title Running web export blanks screen once 1000 objects are visible in scene due to threaded culling Running no-threads web export blanks screen once 1000 objects are visible in scene due to threaded culling when threads Feb 12, 2024
@Calinou Calinou moved this to Very Bad in 4.x Release Blockers Oct 12, 2024
@Calinou Calinou added this to the 4.4 milestone Oct 12, 2024
@Calinou Calinou changed the title Running no-threads web export blanks screen once 1000 objects are visible in scene due to threaded culling when threads Running no-threads web export blanks screen once 1000 objects are visible in scene due to threaded culling being incorrectly used Oct 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment