diff --git a/src/Time/light.cxx b/src/Time/light.cxx index c43ec333f..2e380e59b 100644 --- a/src/Time/light.cxx +++ b/src/Time/light.cxx @@ -164,6 +164,9 @@ void FGLight::bind () { prop->tie("/rendering/dome/sky/red",SGRawValuePointer(&_sky_color[0])); prop->tie("/rendering/dome/sky/green",SGRawValuePointer(&_sky_color[1])); prop->tie("/rendering/dome/sky/blue",SGRawValuePointer(&_sky_color[2])); + prop->tie("/rendering/dome/cloud/red",SGRawValuePointer(&_cloud_color[0])); + prop->tie("/rendering/dome/cloud/green",SGRawValuePointer(&_cloud_color[1])); + prop->tie("/rendering/dome/cloud/blue",SGRawValuePointer(&_cloud_color[2])); prop->tie("/rendering/dome/fog/red",SGRawValuePointer(&_fog_color[0])); prop->tie("/rendering/dome/fog/green",SGRawValuePointer(&_fog_color[1])); prop->tie("/rendering/dome/fog/blue",SGRawValuePointer(&_fog_color[2])); @@ -198,6 +201,9 @@ void FGLight::unbind () { prop->untie("/rendering/dome/sky/red"); prop->untie("/rendering/dome/sky/green"); prop->untie("/rendering/dome/sky/blue"); + prop->untie("/rendering/dome/cloud/red"); + prop->untie("/rendering/dome/cloud/green"); + prop->untie("/rendering/dome/cloud/blue"); prop->untie("/rendering/dome/fog/red"); prop->untie("/rendering/dome/fog/green"); prop->untie("/rendering/dome/fog/blue"); @@ -271,6 +277,7 @@ void FGLight::update_sky_color () { _sky_color[3] = base_sky_color[3]; gamma_correct_rgb( _sky_color.data() ); + sqrt_sky_brightness /= _scattering; _cloud_color[0] = base_fog_color[0] * sky_brightness; _cloud_color[1] = base_fog_color[1] * sky_brightness; _cloud_color[2] = base_fog_color[2] * sky_brightness;