aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkDevice.cpp
diff options
context:
space:
mode:
authorGravatar reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2011-02-22 20:56:26 +0000
committerGravatar reed@google.com <reed@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>2011-02-22 20:56:26 +0000
commit46799cd9f0bded51a189d77731b25af159ab4609 (patch)
tree743fb64d8fce77dbfd8d079b96e07dae0a8db17e /src/core/SkDevice.cpp
parent5d32fc4c1cb2a5ee68cd5e195a5959f800cc3bc7 (diff)
change virtual setMatrixClip() to take a SkClipStack parameter.
git-svn-id: http://skia.googlecode.com/svn/trunk@831 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/core/SkDevice.cpp')
-rw-r--r--src/core/SkDevice.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/core/SkDevice.cpp b/src/core/SkDevice.cpp
index 8df0e41d72..2383ed98b8 100644
--- a/src/core/SkDevice.cpp
+++ b/src/core/SkDevice.cpp
@@ -11,7 +11,7 @@ SkDevice::SkDevice(SkCanvas* canvas, const SkBitmap& bitmap, bool isForLayer)
// auto-allocate if we're for offscreen drawing
if (isForLayer) {
if (NULL == fBitmap.getPixels() && NULL == fBitmap.pixelRef()) {
- fBitmap.allocPixels();
+ fBitmap.allocPixels();
if (!fBitmap.isOpaque()) {
fBitmap.eraseColor(0);
}
@@ -43,7 +43,7 @@ void SkDevice::getBounds(SkIRect* bounds) const {
bool SkDevice::intersects(const SkIRect& r, SkIRect* sect) const {
SkIRect bounds;
-
+
this->getBounds(&bounds);
return sect ? sect->intersect(r, bounds) : SkIRect::Intersects(r, bounds);
}
@@ -54,7 +54,8 @@ void SkDevice::eraseColor(SkColor eraseColor) {
void SkDevice::onAccessBitmap(SkBitmap* bitmap) {}
-void SkDevice::setMatrixClip(const SkMatrix&, const SkRegion&) {}
+void SkDevice::setMatrixClip(const SkMatrix&, const SkRegion&,
+ const SkClipStack&) {}
///////////////////////////////////////////////////////////////////////////////
@@ -116,7 +117,7 @@ void SkDevice::drawBitmap(const SkDraw& draw, const SkBitmap& bitmap,
const SkMatrix& matrix, const SkPaint& paint) {
SkBitmap tmp; // storage if we need a subset of bitmap
const SkBitmap* bitmapPtr = &bitmap;
-
+
if (srcRect) {
if (!bitmap.extractSubset(&tmp, *srcRect)) {
return; // extraction failed