Index: src/effects/SkBlurImageFilter.cpp |
diff --git a/src/effects/SkBlurImageFilter.cpp b/src/effects/SkBlurImageFilter.cpp |
index 00064d4668e664b5b95246671e64041b9d9f2e8a..2961d867d7845becf22e9d2bf48047f08577598e 100644 |
--- a/src/effects/SkBlurImageFilter.cpp |
+++ b/src/effects/SkBlurImageFilter.cpp |
@@ -163,11 +163,10 @@ bool SkBlurImageFilter::onFilterImage(Proxy* proxy, |
return false; |
} |
- dst->setConfig(src.config(), srcBounds.width(), srcBounds.height()); |
- dst->getBounds(&dstBounds); |
- if (!dst->allocPixels()) { |
+ if (!dst->allocPixels(src.info().makeWH(srcBounds.width(), srcBounds.height()))) { |
return false; |
} |
+ dst->getBounds(&dstBounds); |
SkVector sigma = SkVector::Make(fSigma.width(), fSigma.height()); |
ctx.ctm().mapVectors(&sigma, 1); |
@@ -191,8 +190,7 @@ bool SkBlurImageFilter::onFilterImage(Proxy* proxy, |
} |
SkBitmap temp; |
robertphillips
2014/06/02 13:15:59
why not just "dst->info()"?
reed1
2014/06/02 19:43:06
Done.
|
- temp.setConfig(dst->config(), dst->width(), dst->height()); |
- if (!temp.allocPixels()) { |
+ if (!temp.allocPixels(dst->info().makeWH(dst->width(), dst->height()))) { |
return false; |
} |