diff --git a/apps/launcher/advancedpage.cpp b/apps/launcher/advancedpage.cpp
index dc32a80336..eb1a88ea59 100644
--- a/apps/launcher/advancedpage.cpp
+++ b/apps/launcher/advancedpage.cpp
@@ -117,7 +117,6 @@ bool Launcher::AdvancedPage::loadSettings()
loadSettingBool(autoUseTerrainNormalMapsCheckBox, "auto use terrain normal maps", "Shaders");
loadSettingBool(autoUseTerrainSpecularMapsCheckBox, "auto use terrain specular maps", "Shaders");
loadSettingBool(bumpMapLocalLightingCheckBox, "apply lighting to environment maps", "Shaders");
- loadSettingBool(radialFogCheckBox, "radial fog", "Fog");
loadSettingBool(softParticlesCheckBox, "soft particles", "Shaders");
loadSettingBool(antialiasAlphaTestCheckBox, "antialias alpha test", "Shaders");
if (Settings::Manager::getInt("antialiasing", "Video") == 0) {
@@ -151,6 +150,12 @@ bool Launcher::AdvancedPage::loadSettings()
loadSettingBool(postprocessLiveReloadCheckBox, "live reload", "Post Processing");
loadSettingBool(postprocessTransparentPostpassCheckBox, "transparent postpass", "Post Processing");
postprocessHDRTimeComboBox->setValue(Settings::Manager::getDouble("hdr exposure time", "Post Processing"));
+
+ connect(skyBlendingCheckBox, SIGNAL(toggled(bool)), this, SLOT(slotSkyBlendingToggled(bool)));
+ loadSettingBool(radialFogCheckBox, "radial fog", "Fog");
+ loadSettingBool(exponentialFogCheckBox, "exponential fog", "Fog");
+ loadSettingBool(skyBlendingCheckBox, "sky blending", "Fog");
+ skyBlendingStartComboBox->setValue(Settings::Manager::getDouble("sky blending start", "Fog"));
}
// Audio
@@ -302,6 +307,11 @@ void Launcher::AdvancedPage::saveSettings()
double hdrExposureTime = postprocessHDRTimeComboBox->value();
if (hdrExposureTime != Settings::Manager::getDouble("hdr exposure time", "Post Processing"))
Settings::Manager::setDouble("hdr exposure time", "Post Processing", hdrExposureTime);
+
+ saveSettingBool(radialFogCheckBox, "radial fog", "Fog");
+ saveSettingBool(exponentialFogCheckBox, "exponential fog", "Fog");
+ saveSettingBool(skyBlendingCheckBox, "sky blending", "Fog");
+ Settings::Manager::setDouble("sky blending start", "Fog", skyBlendingStartComboBox->value());
}
// Audio
@@ -454,3 +464,9 @@ void Launcher::AdvancedPage::slotPostProcessToggled(bool checked)
postprocessHDRTimeComboBox->setEnabled(checked);
postprocessHDRTimeLabel->setEnabled(checked);
}
+
+void Launcher::AdvancedPage::slotSkyBlendingToggled(bool checked)
+{
+ skyBlendingStartComboBox->setEnabled(checked);
+ skyBlendingStartLabel->setEnabled(checked);
+}
diff --git a/apps/launcher/advancedpage.hpp b/apps/launcher/advancedpage.hpp
index 20b44ff9da..a011602da8 100644
--- a/apps/launcher/advancedpage.hpp
+++ b/apps/launcher/advancedpage.hpp
@@ -30,6 +30,7 @@ namespace Launcher
void on_runScriptAfterStartupBrowseButton_clicked();
void slotAnimSourcesToggled(bool checked);
void slotPostProcessToggled(bool checked);
+ void slotSkyBlendingToggled(bool checked);
private:
Config::GameSettings &mGameSettings;
diff --git a/files/ui/advancedpage.ui b/files/ui/advancedpage.ui
index 66ebd90a80..0a662fc091 100644
--- a/files/ui/advancedpage.ui
+++ b/files/ui/advancedpage.ui
@@ -434,17 +434,16 @@
-
-
-
- <html><head/><body><p>By default, the fog becomes thicker proportionally to your distance from the clipping plane set at the clipping distance, which causes distortion at the edges of the screen.
- This setting makes the fog use the actual eye point distance (or so called Euclidean distance) to calculate the fog, which makes the fog look less artificial, especially if you have a wide FOV.</p></body></html>
-
-
- Radial fog
-
-
-
- -
+
+
+ <html><head/><body><p>Allows MSAA to work with alpha-tested meshes, producing better-looking edges without pixelation. Can negatively impact performance.</p></body></html>
+
+
+ Use anti-alias alpha testing
+
+
+
+ -
<html><head/><body><p>Enables soft particles for particle effects. This technique softens the intersection between individual particles and other opaque geometry by blending between them.</p></body></html>
@@ -454,19 +453,81 @@
- -
-
-
- <html><head/><body><p>Allows MSAA to work with alpha-tested meshes, producing better-looking edges without pixelation. Can negatively impact performance.</p></body></html>
-
-
- Use anti-alias alpha testing
-
-
-
+ -
+
+
+ Fog
+
+
+
-
+
+
+ <html><head/><body><p>By default, the fog becomes thicker proportionally to your distance from the clipping plane set at the clipping distance, which causes distortion at the edges of the screen.
+ This setting makes the fog use the actual eye point distance (or so called Euclidean distance) to calculate the fog, which makes the fog look less artificial, especially if you have a wide FOV.</p></body></html>
+
+
+ Radial fog
+
+
+
+ -
+
+
+ <html><head/><body><p>Use exponential fog formula. By default, linear fog is used.</p></body></html>
+
+
+ Exponential fog
+
+
+
+ -
+
+
+ <html><head/><body><p>Reduce visibility of clipping plane by blending objects with the sky.</p></body></html>
+
+
+ Sky blending
+
+
+
+ -
+
+
+ false
+
+
+ Sky blending start
+
+
+ <html><head/><body><p>The fraction of the maximum distance at which blending with the sky starts.</p></body></html>
+
+
+
+ -
+
+
+ false
+
+
+ 3
+
+
+ 0.000000000000000
+
+
+ 1.000000000000000
+
+
+ 0.005000000000000
+
+
+
+
+
+
-
@@ -626,36 +687,36 @@
-
-
-
-
- false
-
-
- <html><head/><body><p>Controls how much eye adaptation can change from frame to frame. Smaller values makes for slower transitions.</p></body></html>
-
-
- HDR exposure time
-
-
+
+
+ false
+
+
+ <html><head/><body><p>Controls how much eye adaptation can change from frame to frame. Smaller values makes for slower transitions.</p></body></html>
+
+
+ HDR exposure time
+
+
-
-
-
- false
-
-
- 3
-
-
- 0.000000000000000
-
-
- 1.000000000000000
-
-
- 0.001000000000000
-
-
+
+
+ false
+
+
+ 3
+
+
+ 0.000000000000000
+
+
+ 1.000000000000000
+
+
+ 0.001000000000000
+
+