[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [23967] trunk/blender/source/blender/ editors/space_view3d/drawobject.c: Fix #19523: spot lamp blend display size was tweaked so it was always

Brecht Van Lommel brecht at blender.org
Mon Oct 19 17:53:57 CEST 2009


Revision: 23967
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=23967
Author:   blendix
Date:     2009-10-19 17:53:57 +0200 (Mon, 19 Oct 2009)

Log Message:
-----------
Fix #19523: spot lamp blend display size was tweaked so it was always
showing, but that also is confusing because it then shows the wrong
size, so just hide it now when blend size is 0 or 1.

Modified Paths:
--------------
    trunk/blender/source/blender/editors/space_view3d/drawobject.c

Modified: trunk/blender/source/blender/editors/space_view3d/drawobject.c
===================================================================
--- trunk/blender/source/blender/editors/space_view3d/drawobject.c	2009-10-19 15:01:07 UTC (rev 23966)
+++ trunk/blender/source/blender/editors/space_view3d/drawobject.c	2009-10-19 15:53:57 UTC (rev 23967)
@@ -922,11 +922,11 @@
 		/* draw the circle/square representing spotbl */
 		if(la->type==LA_SPOT) {
 			float spotblcirc = fabs(z)*(1 - pow(la->spotblend, 2));
-			/* make sure the line is always visible - prevent it from reaching the outer border (or 0) 
-			 * values are kinda arbitrary - just what seemed to work well */
-			if (spotblcirc == 0) spotblcirc = 0.15;
-			else if (spotblcirc == fabs(z)) spotblcirc = fabs(z) - 0.07;
-			circ(0.0, 0.0, spotblcirc);
+			/* hide line if it is zero size or overlaps with outer border,
+			   previously it adjusted to always to show it but that seems
+			   confusing because it doesn't show the actual blend size */
+			if (spotblcirc != 0 && spotblcirc != fabs(z))
+				circ(0.0, 0.0, spotblcirc);
 		}
 		
 	}





More information about the Bf-blender-cvs mailing list