[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [46765] branches/soc-2011-tomato/source/ blender/editors/transform/transform.c: fix error with mask translation not quite following the mouse.

Campbell Barton ideasman42 at gmail.com
Fri May 18 12:02:14 CEST 2012


Revision: 46765
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=46765
Author:   campbellbarton
Date:     2012-05-18 10:02:14 +0000 (Fri, 18 May 2012)
Log Message:
-----------
fix error with mask translation not quite following the mouse.

Modified Paths:
--------------
    branches/soc-2011-tomato/source/blender/editors/transform/transform.c

Modified: branches/soc-2011-tomato/source/blender/editors/transform/transform.c
===================================================================
--- branches/soc-2011-tomato/source/blender/editors/transform/transform.c	2012-05-18 10:00:31 UTC (rev 46764)
+++ branches/soc-2011-tomato/source/blender/editors/transform/transform.c	2012-05-18 10:02:14 UTC (rev 46765)
@@ -173,7 +173,7 @@
 
 		if (t->options & CTX_MASK) {
 			/* clamp w/h, mask only */
-			divx = divy = minf(divx, divy);
+			divx = divy = maxf(divx, divy);
 			mulx = muly = minf(mulx, muly);
 		}
 
@@ -181,6 +181,7 @@
 		r_vec[1] = muly * (dy) / divy;
 		r_vec[2] = 0.0f;
 
+		/* TODO - NOT WORKING, this isnt so bad since its only display aspect */
 		if (t->options & CTX_MASK) {
 			float aspx, aspy;
 			ED_space_clip_mask_aspect(t->sa->spacedata.first, &aspx, &aspy);




More information about the Bf-blender-cvs mailing list