| Index: src/core/SkBitmapDevice.cpp
|
| diff --git a/src/core/SkBitmapDevice.cpp b/src/core/SkBitmapDevice.cpp
|
| index 119a434cc9cde8a5077a18702ba2394e67a183f8..d1dcb20dfc0d5fd7f5a8c61785bb065e6d4c250f 100644
|
| --- a/src/core/SkBitmapDevice.cpp
|
| +++ b/src/core/SkBitmapDevice.cpp
|
| @@ -302,8 +302,14 @@ void SkBitmapDevice::drawBitmapRect(const SkDraw& draw, const SkBitmap& bitmap,
|
| matrix.preTranslate(dx, dy);
|
| }
|
|
|
| +#ifdef SK_DRAWBITMAPRECT_FAST_OFFSET
|
| + SkRect extractedBitmapBounds = SkRect::MakeXYWH(dx, dy,
|
| + SkIntToScalar(bitmapPtr->width()),
|
| + SkIntToScalar(bitmapPtr->height()));
|
| +#else
|
| SkRect extractedBitmapBounds;
|
| extractedBitmapBounds.isetWH(bitmapPtr->width(), bitmapPtr->height());
|
| +#endif
|
| if (extractedBitmapBounds == tmpSrc) {
|
| // no fractional part in src, we can just call drawBitmap
|
| goto USE_DRAWBITMAP;
|
|
|