Since I had a look into the shaders I also extended the drawing distance for fading objects.
The modified object shaders:
Update V1.1: fixed incorrect calculation of object distances outside the view center.
sf2_extfadingdistance_shaders_v1.1.zip
-Copy the shader files (*.fx) into the Terrains\<terrain> folder.
-Adjust the variables fadeStartDistance and fadeLength to your likings in the follwing code section of both shader files:
float fade_with_distance(float FadeDist)
{
float fade_alpha = 1.0;
//mue: distance at which the object still has alpha = 1.0 (full opaque)
const float fadeStartDistance = 16000.0; //in meters
//mue: fadeStartDistance + fadeLength = distance at which the object has alpha = 0.0 (full transparent)
const float fadeLength = 3000.0; //in meters
const float fd = FadeDist - fadeStartDistance;
if (fd > 0.0)
{
fade_alpha = clamp(0.0, 1.0, 1.0 - (fd / fadeLength));
}
return (fade_alpha);
}
-Set in flightengine.ini DetailMeshSize so that
(fadeStartDistance + fadeLength) / terrain_tile_size < DetailMeshSize
-Set in options.ini ObjectsFade=false
-Enjoy your flight!