[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [59671] trunk/blender/intern/cycles/render /nodes.cpp: Fix for [#36610] The new sky model produces strange results
Thomas Dinges
blender at dingto.org
Fri Aug 30 20:04:24 CEST 2013
Revision: 59671
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=59671
Author: dingto
Date: 2013-08-30 18:04:23 +0000 (Fri, 30 Aug 2013)
Log Message:
-----------
Fix for [#36610] The new sky model produces strange results
* Clamp theta sky coordinates, to prevent a negative solarElevation.
Note: This means that you cannot get absolute night with the new model, but this is not supported anyway. So when you reach the maximum sunset, use the World Strength to further decrease the light.
Modified Paths:
--------------
trunk/blender/intern/cycles/render/nodes.cpp
Modified: trunk/blender/intern/cycles/render/nodes.cpp
===================================================================
--- trunk/blender/intern/cycles/render/nodes.cpp 2013-08-30 17:34:27 UTC (rev 59670)
+++ trunk/blender/intern/cycles/render/nodes.cpp 2013-08-30 18:04:23 UTC (rev 59671)
@@ -464,6 +464,9 @@
float2 spherical = sky_spherical_coordinates(dir);
float theta = spherical.x;
float phi = spherical.y;
+
+ /* Clamp to Horizon */
+ theta = clamp(theta, 0.0f, M_PI_2_F);
sunsky->theta = theta;
sunsky->phi = phi;
More information about the Bf-blender-cvs
mailing list