diff options
| -rw-r--r-- | indra/newview/llfloaterpreference.cpp | 24 | ||||
| -rw-r--r-- | indra/newview/llfloaterpreference.h | 1 | 
2 files changed, 24 insertions, 1 deletions
diff --git a/indra/newview/llfloaterpreference.cpp b/indra/newview/llfloaterpreference.cpp index bb4ddf5969..531270f936 100644 --- a/indra/newview/llfloaterpreference.cpp +++ b/indra/newview/llfloaterpreference.cpp @@ -793,7 +793,8 @@ void LLFloaterPreference::setHardwareDefaults()  void LLFloaterPreference::setRecommendedSettings()  { -    gSavedSettings.setBOOL("AutoTuneFPS", FALSE); +    resetAutotuneSettings(); +    gSavedSettings.getControl("RenderVSyncEnable")->resetToDefault(true);  	LLFeatureManager::getInstance()->applyRecommendedSettings(); @@ -818,6 +819,27 @@ void LLFloaterPreference::setRecommendedSettings()  	}  } +void LLFloaterPreference::resetAutotuneSettings() +{ +    gSavedSettings.setBOOL("AutoTuneFPS", FALSE); + +    const std::string autotune_settings[] = { +        "AutoTuneLock", +        "TargetFPS", +        "TuningFPSStrategy", +        "AutoTuneImpostorByDistEnabled", +        "AutoTuneImpostorFarAwayDistance" , +        "AutoTuneRenderFarClipMin", +        "AutoTuneRenderFarClipTarget", +        "RenderAvatarMaxART" +    }; + +    for (auto it : autotune_settings) +    { +        gSavedSettings.getControl(it)->resetToDefault(true); +    } +} +  void LLFloaterPreference::getControlNames(std::vector<std::string>& names)  {  	LLView* view = findChild<LLView>("display"); diff --git a/indra/newview/llfloaterpreference.h b/indra/newview/llfloaterpreference.h index 32a55a2948..2aa6ca87b7 100644 --- a/indra/newview/llfloaterpreference.h +++ b/indra/newview/llfloaterpreference.h @@ -200,6 +200,7 @@ public:  	void saveGraphicsPreset(std::string& preset);      void setRecommendedSettings(); +    void resetAutotuneSettings();  private:  | 
