aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/effects
diff options
context:
space:
mode:
authorGravatar reed <reed@chromium.org>2015-06-08 19:58:07 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-06-08 19:58:07 -0700
commitb3f0ec9f9967da2f80f0d842cb7fd53617b48de3 (patch)
treef00f2095e30e48180a2a3a073be5bf1a1fe3f4c2 /src/effects
parent86ae0a9e465f157eaa263ef7515e10619946ff83 (diff)
Revert of change SkDraw and all Blitters to use pixmap instead of bitmap (patchset #6 id:100001 of https://codereview.chromium.org/1148793007/)
Reason for revert: speculative revert to try to unblock DEPS roll Original issue's description: > change SkDraw and all Blitters to use pixmap instead of bitmap > > BUG=skia: > > Committed: https://skia.googlesource.com/skia/+/c31af44336f5eb4a50e83e76e51962d46c3ed458 TBR=scroggo@google.com,jvanverth@google.com,reed@google.com NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review URL: https://codereview.chromium.org/1164373003
Diffstat (limited to 'src/effects')
-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 8403d06147..d3e112c3a4 100644
--- a/src/effects/SkLayerRasterizer.cpp
+++ b/src/effects/SkLayerRasterizer.cpp
@@ -116,12 +116,9 @@ bool SkLayerRasterizer::onRasterize(const SkPath& path, const SkMatrix& matrix,
}
if (SkMask::kJustComputeBounds_CreateMode != mode) {
- SkDraw draw;
- if (!draw.fDst.reset(*mask)) {
- return false;
- }
-
+ SkBitmap device;
SkRasterClip rectClip;
+ SkDraw draw;
SkMatrix translatedMatrix; // this translates us to our local pixels
SkMatrix drawMatrix; // this translates the path by each layer's offset
@@ -131,6 +128,9 @@ 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();