Change editor FPS limit for unfocused mode back to 20 FPS

This was changed in 7991d0fb22 but seems to cause issues
for some projects when using the profiler.

Fixes #51222.
This commit is contained in:
Rémi Verschelde 2021-10-12 16:56:09 +02:00
parent f7fd5e3aeb
commit 779a5e5621
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -334,7 +334,9 @@ void EditorSettings::_load_defaults(Ref<ConfigFile> p_extra_config) {
_initial_set("interface/editor/dim_editor_on_dialog_popup", true);
_initial_set("interface/editor/low_processor_mode_sleep_usec", 6900); // ~144 FPS
hints["interface/editor/low_processor_mode_sleep_usec"] = PropertyInfo(Variant::REAL, "interface/editor/low_processor_mode_sleep_usec", PROPERTY_HINT_RANGE, "1,100000,1", PROPERTY_USAGE_DEFAULT | PROPERTY_USAGE_RESTART_IF_CHANGED);
_initial_set("interface/editor/unfocused_low_processor_mode_sleep_usec", 100000); // 10 FPS
// Note: Don't go low on the editor unfocused FPS, as it seems to cause stalls in the game
// when using the profiler (see GH-51222).
_initial_set("interface/editor/unfocused_low_processor_mode_sleep_usec", 50000); // 20 FPS
// Allow an unfocused FPS limit as low as 1 FPS for those who really need low power usage
// (but don't need to preview particles or shaders while the editor is unfocused).
// With very low FPS limits, the editor can take a small while to become usable after being focused again,