paysages: Small clouds lighting improvement.
git-svn-id: https://subversion.assembla.com/svn/thunderk/paysages@193 b1fd45b6-86a6-48da-8261-f70d1f35bdcc
This commit is contained in:
parent
763e75f77e
commit
680a8e8c32
1 changed files with 5 additions and 3 deletions
|
@ -403,6 +403,8 @@ static Color _applyLayerLighting(CloudsDefinition* definition, CloudsQuality* qu
|
|||
Color result;
|
||||
|
||||
normal = _getNormal(definition, position, 0.5);
|
||||
normal = v3Add(normal, _getNormal(definition, position, 0.2));
|
||||
normal = v3Add(normal, _getNormal(definition, position, 0.1));
|
||||
result = lightingApply(position, normal, 0.0, base, 0.3, 0.1);
|
||||
|
||||
direction = sun_direction_inv;
|
||||
|
@ -416,9 +418,9 @@ static Color _applyLayerLighting(CloudsDefinition* definition, CloudsQuality* qu
|
|||
inside_depth = 1.0;
|
||||
}
|
||||
|
||||
result.r = base.r * sun_color_lum * (0.9 - 0.2 * inside_depth) + result.r * 0.2 * inside_depth + (0.1 - inside_depth * 0.1) * sun_color_lum;
|
||||
result.g = base.g * sun_color_lum * (0.9 - 0.2 * inside_depth) + result.g * 0.2 * inside_depth + (0.1 - inside_depth * 0.1) * sun_color_lum;
|
||||
result.b = base.b * sun_color_lum * (0.9 - 0.2 * inside_depth) + result.b * 0.2 * inside_depth + (0.1 - inside_depth * 0.1) * sun_color_lum;
|
||||
result.r = base.r * sun_color_lum * (0.9 - 0.2 * inside_depth) + result.r * (0.1 + 0.1 * inside_depth) + (0.1 - inside_depth * 0.1) * sun_color_lum;
|
||||
result.g = base.g * sun_color_lum * (0.9 - 0.2 * inside_depth) + result.g * (0.1 + 0.1 * inside_depth) + (0.1 - inside_depth * 0.1) * sun_color_lum;
|
||||
result.b = base.b * sun_color_lum * (0.9 - 0.2 * inside_depth) + result.b * (0.1 + 0.1 * inside_depth) + (0.1 - inside_depth * 0.1) * sun_color_lum;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue