-
-
Notifications
You must be signed in to change notification settings - Fork 22k
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
Godot4 using > 80% of the CPU when moving a directional light #65894
Comments
Can't reproduce on M1 mac, It's about 1% on background and 6% idle on foreground. |
Related to #64708. |
Could be but in the above comment I have a screenshot showing the godot window unobstructed in the foreground 🤔 |
Hmm I tried to build godot 4 to check this in a profiler but then I created a new project and the issue disappeared. The original project I opened was actually the one referenced in this issue: #53969 So this issue still persists, but it seems now it has become a CPU bound operation. |
This is the project which causes the CPU drop @bruvzg |
@Calinou is this expecting too much from the renderer? We are moving the directional light every frame after all 🤔 |
Yes, this should be avoided when possible. AAA games that feature day/night cycles will generally move the light only 20 times per cycle or so, snapping between increments every so often (with a small period of continuous transition that only lasts a few seconds). Changing the sky update mode to Real-Time in the Environment resource should help decrease CPU/GPU usage a bit when updating the sky, but moving the light continuously all the time should still be avoided. |
It's the same, 7-8% on M1 mac, probably it's an issue with a older Intel GPUs. |
@tavurth How is your performance when using the realtime update mode? When updating every single frame the realtime update mode is likely a better option than then automatic mode. In either case though, updating the sky every frame on a low powered integrated GPU is probably going to consume a large portion of your frame budget. I recommend setting the DirectionaLight3D's |
Ok this is weird but I now have around 18% CPU usage in the same scene. The only thing I've changed is renaming the folder. Could it be that Godot4 is somehow re-using the cached shaders from the previous Godot3 version? Renaming the folder back does not bring back the CPU usage however. I will close this for now as sadly non-reproducible 🤷 |
Godot version
Beta 1
System information
MacBook Pro (13-inch, 2019) 2.4 GHz Quad-Core Intel Core i5
Issue description
When starting a blank project in the new Godot4 beta I see >80% of the CPU being used at all times.
The godot editor also frequently becomes unresponsive, showing as
Not responding
in the task manager.Steps to reproduce
Minimal reproduction project
godot_directional_light.zip
The text was updated successfully, but these errors were encountered: