SOme adjustments
This commit is contained in:
parent
81e9a162be
commit
9b228bff61
2 changed files with 8 additions and 3 deletions
|
@ -121,8 +121,13 @@ Color CloudShader::lightMarch(const Scene &scene, Vector3d currentInCloudPositio
|
|||
float transmittance = getDensityTransmittance(density);
|
||||
float scatter = scatterFactor(normalized(lengthDistance), illumination.direction);
|
||||
|
||||
float factor = settings.darknessThreshold +
|
||||
(1.0f - settings.darknessThreshold) * (transmittance * scatter); // (transmittance * scatter)
|
||||
float factor = transmittance;
|
||||
if (density > 0)
|
||||
{
|
||||
factor = settings.darknessThreshold +
|
||||
(1.0f - settings.darknessThreshold) * factor * scatter;
|
||||
}
|
||||
|
||||
cloudColor += factor * illumination.color;
|
||||
}
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ struct CloudSettings
|
|||
float scale = 10;
|
||||
float densityOffset = -0.57f;
|
||||
float densityIntensity = 7.0f; // 7.0f
|
||||
float darknessThreshold = 0.07f; // 0.07f
|
||||
float darknessThreshold = 0.1f; // 0.07f
|
||||
float shadowIntensity = 0.6f;
|
||||
float shadowLightAbsorption = 1;
|
||||
float lightAbsorptionTowardsLight = 1.0f;
|
||||
|
|
Loading…
Reference in a new issue