add proper support for solid style, and temporarily turn off my change so the bots...
authorhumper@google.com <humper@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Mon, 11 Mar 2013 22:18:54 +0000 (22:18 +0000)
committerhumper@google.com <humper@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Mon, 11 Mar 2013 22:18:54 +0000 (22:18 +0000)
git-svn-id: http://skia.googlecode.com/svn/trunk@8085 2bbb7eff-a529-9590-31e7-b0007b416f81

gyp/effects.gyp
src/effects/SkBlurMask.cpp

index e110c9f..fa9fd27 100644 (file)
@@ -23,6 +23,9 @@
       'sources': [
         'effects.gypi', # Makes the gypi appear in IDEs (but does not modify the build).
       ],
+      'defines': [
+        'SK_IGNORE_FAST_RECT_BLUR=1',
+      ],
       'conditions': [
         ['skia_gpu == 1', {
           'include_dirs': [
index 97b5ab3..3b36702 100644 (file)
@@ -1242,7 +1242,7 @@ bool SkBlurMask::BlurRect(SkMask *dst, const SkRect &src,
                           SkScalar provided_radius, Style style,
                           SkIPoint *margin, SkMask::CreateMode createMode) {
     int profile_size;
-
+    
     float radius = SkScalarToFloat(SkScalarMul(provided_radius, kBlurRadiusFudgeFactor));
 
     // adjust blur radius to match interpretation from boxfilter code
@@ -1356,6 +1356,11 @@ bool SkBlurMask::BlurRect(SkMask *dst, const SkRect &src,
             uint8_t *dst_scanline = dp + y*dstWidth + pad;
             memset(dst_scanline, 0, sw);
         }
+    } else if (style == kSolid_Style) {
+        for (int y = pad ; y < dstHeight-pad ; y++) {
+            uint8_t *dst_scanline = dp + y*dstWidth + pad;
+            memset(dst_scanline, 0xff, sw);
+        }        
     }
     // normal and solid styles are the same for analytic rect blurs, so don't
     // need to handle solid specially.