[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [2356] trunk/py/scripts/addons/ render_povray/render.py: Another tiny tweak to area lights and API update ( jitter > use_jitter)

Maurice Raybaud mauriceraybaud at hotmail.fr
Mon Sep 26 00:03:36 CEST 2011


Revision: 2356
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-extensions&revision=2356
Author:   mauriceraybaud
Date:     2011-09-25 22:03:35 +0000 (Sun, 25 Sep 2011)
Log Message:
-----------
Another tiny tweak to area lights and API update (jitter > use_jitter)

Modified Paths:
--------------
    trunk/py/scripts/addons/render_povray/render.py

Modified: trunk/py/scripts/addons/render_povray/render.py
===================================================================
--- trunk/py/scripts/addons/render_povray/render.py	2011-09-25 03:20:48 UTC (rev 2355)
+++ trunk/py/scripts/addons/render_povray/render.py	2011-09-25 22:03:35 UTC (rev 2356)
@@ -616,7 +616,8 @@
                 tabWrite("point_at  <0, 0, -1>\n")  # *must* be after 'parallel'
 
             elif lamp.type == 'AREA':
-                tabWrite("fade_distance %.6f\n" % (lamp.distance / 5.0))
+                tabWrite("area_illumination\n")
+                tabWrite("fade_distance %.6f\n" % (lamp.distance / 2.0))
                 # Area lights have no falloff type, so always use blenders lamp quad equivalent
                 # for those?
                 tabWrite("fade_power %d\n" % 2)
@@ -630,9 +631,9 @@
                     samples_y = lamp.shadow_ray_samples_y
 
                 tabWrite("area_light <%.6f,0,0>,<0,%.6f,0> %d, %d\n" % \
-                         (size_x, -size_y, samples_x, samples_y))
+                         (size_x, size_y, samples_x, samples_y))
                 if lamp.shadow_ray_sample_method == 'CONSTANT_JITTERED':
-                    if lamp.jitter:
+                    if lamp.use_jitter:
                         tabWrite("jitter\n")
                 else:
                     tabWrite("adaptive 1\n")
@@ -646,7 +647,7 @@
             # Sun shouldn't be attenuated. Hemi and area lights have no falloff attribute so they
             # are put to type 2 attenuation a little higher above.
             if lamp.type not in {'SUN', 'AREA', 'HEMI'}:
-                tabWrite("fade_distance %.6f\n" % (lamp.distance / 5.0))
+                tabWrite("fade_distance %.6f\n" % (lamp.distance / 2.0))
                 if lamp.falloff_type == 'INVERSE_SQUARE':
                     tabWrite("fade_power %d\n" % 2)  # Use blenders lamp quad equivalent
                 elif lamp.falloff_type == 'INVERSE_LINEAR':



More information about the Bf-extensions-cvs mailing list