Fixed a bug I introduced in r400. When rendering a rectange, if we find that it...
authordooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Fri, 6 Apr 2007 12:14:26 +0000 (12:14 +0000)
committerdooglus <dooglus@1f10aa63-cdf2-0310-b900-c93c546f37ac>
Fri, 6 Apr 2007 12:14:26 +0000 (12:14 +0000)
git-svn-id: http://svn.voria.com/code@430 1f10aa63-cdf2-0310-b900-c93c546f37ac

synfig-core/trunk/src/modules/mod_geometry/rectangle.cpp

index 799a0f6..48d9e9d 100644 (file)
@@ -489,12 +489,6 @@ Rectangle::accelerated_render(Context context,Surface *surface,int quality, cons
        right = std::min(w,right);
 */
 
-       Surface::alpha_pen pen;
-
-       // In the case where there is nothing to render...
-       if (right < left || bottom < top)
-               return true;
-
        // optimisation - if the whole tile is covered by this rectangle,
        // and the rectangle is a solid colour, we don't need to render
        // what's behind us
@@ -512,6 +506,12 @@ Rectangle::accelerated_render(Context context,Surface *surface,int quality, cons
                return false;
        }
 
+       // In the case where there is nothing to render...
+       if (right < left || bottom < top)
+               return true;
+
+       Surface::alpha_pen pen;
+
        if(right-left>0&&bottom-top>0)
        {
                if(is_solid_color())