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

Unified Diff: src/core/SkRecordDraw.cpp

Issue 1228083004: add src-rect-constraint to drawImageRect (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 5 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/core/SkPictureRecord.cpp ('k') | src/core/SkRecorder.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkRecordDraw.cpp
diff --git a/src/core/SkRecordDraw.cpp b/src/core/SkRecordDraw.cpp
index 7ef2eafda8c3c93c46cfe4016e679436e4d2f6c0..8ceb9c1337ed0c7b05e27c4ba45be307588f5d37 100644
--- a/src/core/SkRecordDraw.cpp
+++ b/src/core/SkRecordDraw.cpp
@@ -88,14 +88,14 @@ DRAW(ClipRegion, clipRegion(r.region, r.op));
DRAW(DrawBitmap, drawBitmap(r.bitmap.shallowCopy(), r.left, r.top, r.paint));
DRAW(DrawBitmapNine, drawBitmapNine(r.bitmap.shallowCopy(), r.center, r.dst, r.paint));
-DRAW(DrawBitmapRectToRect,
- drawBitmapRectToRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint,
- SkCanvas::kNone_DrawBitmapRectFlag));
-DRAW(DrawBitmapRectToRectBleed,
- drawBitmapRectToRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint,
- SkCanvas::kBleed_DrawBitmapRectFlag));
-DRAW(DrawBitmapRectToRectFixedSize,
- drawBitmapRectToRect(r.bitmap.shallowCopy(), &r.src, r.dst, &r.paint, r.flags));
+DRAW(DrawBitmapRect,
+ drawBitmapRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint,
+ SkCanvas::kStrict_SrcRectConstraint));
+DRAW(DrawBitmapRectFast,
+ drawBitmapRect(r.bitmap.shallowCopy(), r.src, r.dst, r.paint,
+ SkCanvas::kFast_SrcRectConstraint));
+DRAW(DrawBitmapRectFixedSize,
+ drawBitmapRect(r.bitmap.shallowCopy(), &r.src, r.dst, &r.paint, r.constraint));
DRAW(DrawDRRect, drawDRRect(r.outer, r.inner, r.paint));
DRAW(DrawImage, drawImage(r.image, r.left, r.top, r.paint));
DRAW(DrawImageRect, drawImageRect(r.image, r.src, r.dst, r.paint));
@@ -419,13 +419,13 @@ private:
Bounds bounds(const DrawImageNine& op) const {
return this->adjustAndMap(op.dst, op.paint);
}
- Bounds bounds(const DrawBitmapRectToRect& op) const {
+ Bounds bounds(const DrawBitmapRect& op) const {
return this->adjustAndMap(op.dst, op.paint);
}
- Bounds bounds(const DrawBitmapRectToRectBleed& op) const {
+ Bounds bounds(const DrawBitmapRectFast& op) const {
return this->adjustAndMap(op.dst, op.paint);
}
- Bounds bounds(const DrawBitmapRectToRectFixedSize& op) const {
+ Bounds bounds(const DrawBitmapRectFixedSize& op) const {
return this->adjustAndMap(op.dst, &op.paint);
}
Bounds bounds(const DrawBitmapNine& op) const {
« no previous file with comments | « src/core/SkPictureRecord.cpp ('k') | src/core/SkRecorder.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698