aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects/SkLayerRasterizer.cpp
diff options
context:
space:
mode:
authorGravatar reed <reed@google.com>2015-06-08 10:47:12 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-06-08 10:47:13 -0700
commitc31af44336f5eb4a50e83e76e51962d46c3ed458 (patch)
tree244dcbfbeb638de8da65980dd59707ee323c5d24 /src/effects/SkLayerRasterizer.cpp
parent77dcbdeb19d26e52428e392fca0ec9a72658b746 (diff)
change SkDraw and all Blitters to use pixmap instead of bitmap
Diffstat (limited to 'src/effects/SkLayerRasterizer.cpp')
-rw-r--r--src/effects/SkLayerRasterizer.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/effects/SkLayerRasterizer.cpp b/src/effects/SkLayerRasterizer.cpp
index d3e112c3a4..8403d06147 100644
--- a/src/effects/SkLayerRasterizer.cpp
+++ b/src/effects/SkLayerRasterizer.cpp
@@ -116,9 +116,12 @@ bool SkLayerRasterizer::onRasterize(const SkPath& path, const SkMatrix& matrix,
}
if (SkMask::kJustComputeBounds_CreateMode != mode) {
- SkBitmap device;
- SkRasterClip rectClip;
SkDraw draw;
+ if (!draw.fDst.reset(*mask)) {
+ return false;
+ }
+
+ SkRasterClip rectClip;
SkMatrix translatedMatrix; // this translates us to our local pixels
SkMatrix drawMatrix; // this translates the path by each layer's offset
@@ -128,9 +131,6 @@ bool SkLayerRasterizer::onRasterize(const SkPath& path, const SkMatrix& matrix,
translatedMatrix.postTranslate(-SkIntToScalar(mask->fBounds.fLeft),
-SkIntToScalar(mask->fBounds.fTop));
- device.installMaskPixels(*mask);
-
- draw.fBitmap = &device;
draw.fMatrix = &drawMatrix;
draw.fRC = &rectClip;
draw.fClip = &rectClip.bwRgn();