[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [49671] trunk/blender/source/blender/ blenlib/intern/rct.c: fix for own error confusing FLT_MIN with -FLT_MAX ( didnt get into a release, dont include in log)

Campbell Barton ideasman42 at gmail.com
Tue Aug 7 20:41:48 CEST 2012


Revision: 49671
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=49671
Author:   campbellbarton
Date:     2012-08-07 18:41:47 +0000 (Tue, 07 Aug 2012)
Log Message:
-----------
fix for own error confusing FLT_MIN with -FLT_MAX (didnt get into a release, dont include in log)

Modified Paths:
--------------
    trunk/blender/source/blender/blenlib/intern/rct.c

Modified: trunk/blender/source/blender/blenlib/intern/rct.c
===================================================================
--- trunk/blender/source/blender/blenlib/intern/rct.c	2012-08-07 17:20:21 UTC (rev 49670)
+++ trunk/blender/source/blender/blenlib/intern/rct.c	2012-08-07 18:41:47 UTC (rev 49671)
@@ -206,19 +206,19 @@
 	}
 }
 
-void BLI_rcti_init_minmax(struct rcti *rect)
+void BLI_rcti_init_minmax(rcti *rect)
 {
 	rect->xmin = rect->ymin = INT_MAX;
 	rect->xmax = rect->ymax = INT_MIN;
 }
 
-void BLI_rctf_init_minmax(struct rctf *rect)
+void BLI_rctf_init_minmax(rctf *rect)
 {
-	rect->xmin = rect->ymin = FLT_MAX;
-	rect->xmax = rect->ymax = FLT_MIN;
+	rect->xmin = rect->ymin =  FLT_MAX;
+	rect->xmax = rect->ymax = -FLT_MAX;
 }
 
-void BLI_rcti_do_minmax_v(struct rcti *rect, const int xy[2])
+void BLI_rcti_do_minmax_v(rcti *rect, const int xy[2])
 {
 	if (xy[0] < rect->xmin) rect->xmin = xy[0];
 	if (xy[0] > rect->xmax) rect->xmax = xy[0];
@@ -226,7 +226,7 @@
 	if (xy[1] > rect->ymax) rect->ymax = xy[1];
 }
 
-void BLI_rctf_do_minmax_v(struct rctf *rect, const float xy[2])
+void BLI_rctf_do_minmax_v(rctf *rect, const float xy[2])
 {
 	if (xy[0] < rect->xmin) rect->xmin = xy[0];
 	if (xy[0] > rect->xmax) rect->xmax = xy[0];




More information about the Bf-blender-cvs mailing list