Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(303)

Unified Diff: src/gpu/SkGpuDevice.cpp

Issue 19449002: Replace all instances of GrRect with SkRect. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrTextStrike.cpp ('k') | src/gpu/SkGrFontScaler.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/SkGpuDevice.cpp
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index ab7693c7f1c0d1e276a9701fefa5cfebf50c04cb..81b25b82b3b7a8f519a03f18ce6aeb617594099c 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -1280,8 +1280,8 @@ void SkGpuDevice::internalDrawBitmap(const SkBitmap& bitmap,
return;
}
- GrRect dstRect(srcRect);
- GrRect paintRect;
+ SkRect dstRect(srcRect);
+ SkRect paintRect;
SkScalar wInv = SkScalarInvert(SkIntToScalar(bitmap.width()));
SkScalar hInv = SkScalarInvert(SkIntToScalar(bitmap.height()));
paintRect.setLTRB(SkScalarMul(srcRect.fLeft, wInv),
@@ -1296,7 +1296,7 @@ void SkGpuDevice::internalDrawBitmap(const SkBitmap& bitmap,
srcRect.height() < bitmap.height();
if (m.rectStaysRect() && fContext->getMatrix().rectStaysRect()) {
// sampling is axis-aligned
- GrRect transformedRect;
+ SkRect transformedRect;
SkMatrix srcToDeviceMatrix(m);
srcToDeviceMatrix.postConcat(fContext->getMatrix());
srcToDeviceMatrix.mapRect(&transformedRect, srcRect);
@@ -1312,7 +1312,7 @@ void SkGpuDevice::internalDrawBitmap(const SkBitmap& bitmap,
}
}
- GrRect textureDomain = GrRect::MakeEmpty();
+ SkRect textureDomain = SkRect::MakeEmpty();
SkAutoTUnref<GrEffectRef> effect;
if (needsTextureDomain) {
// Use a constrained texture domain to avoid color bleeding
@@ -1405,11 +1405,11 @@ void SkGpuDevice::drawSprite(const SkDraw& draw, const SkBitmap& bitmap,
}
fContext->drawRectToRect(grPaint,
- GrRect::MakeXYWH(SkIntToScalar(left),
+ SkRect::MakeXYWH(SkIntToScalar(left),
SkIntToScalar(top),
SkIntToScalar(w),
SkIntToScalar(h)),
- GrRect::MakeXYWH(SkIntToScalar(offset.fX),
+ SkRect::MakeXYWH(SkIntToScalar(offset.fX),
SkIntToScalar(offset.fY),
SK_Scalar1 * w / texture->width(),
SK_Scalar1 * h / texture->height()));
@@ -1488,14 +1488,14 @@ void SkGpuDevice::drawDevice(const SkDraw& draw, SkDevice* device,
return;
}
- GrRect dstRect = GrRect::MakeXYWH(SkIntToScalar(x),
+ SkRect dstRect = SkRect::MakeXYWH(SkIntToScalar(x),
SkIntToScalar(y),
SkIntToScalar(w),
SkIntToScalar(h));
// The device being drawn may not fill up its texture (e.g. saveLayer uses approximate
// scratch texture).
- GrRect srcRect = GrRect::MakeWH(SK_Scalar1 * w / devTex->width(),
+ SkRect srcRect = SkRect::MakeWH(SK_Scalar1 * w / devTex->width(),
SK_Scalar1 * h / devTex->height());
fContext->drawRectToRect(grPaint, dstRect, srcRect);
« no previous file with comments | « src/gpu/GrTextStrike.cpp ('k') | src/gpu/SkGrFontScaler.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698