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

Unified Diff: src/utils/debugger/SkDrawCommand.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/utils/debugger/SkDrawCommand.h ('k') | tests/RecordDrawTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/utils/debugger/SkDrawCommand.cpp
diff --git a/src/utils/debugger/SkDrawCommand.cpp b/src/utils/debugger/SkDrawCommand.cpp
index 7e2af084f2036c26b599a67d2bc3071a826a2411..5f0f74ffc0051ac30062d9460dc73bb40bdeca49 100644
--- a/src/utils/debugger/SkDrawCommand.cpp
+++ b/src/utils/debugger/SkDrawCommand.cpp
@@ -320,7 +320,7 @@ bool SkDrawBitmapNineCommand::render(SkCanvas* canvas) const {
SkDrawBitmapRectCommand::SkDrawBitmapRectCommand(const SkBitmap& bitmap, const SkRect* src,
const SkRect& dst, const SkPaint* paint,
- SkCanvas::DrawBitmapRectFlags flags)
+ SkCanvas::SrcRectConstraint constraint)
: INHERITED(kDrawBitmapRect_OpType) {
fBitmap = bitmap;
if (src) {
@@ -336,7 +336,7 @@ SkDrawBitmapRectCommand::SkDrawBitmapRectCommand(const SkBitmap& bitmap, const S
} else {
fPaintPtr = NULL;
}
- fFlags = flags;
+ fConstraint = constraint;
fInfo.push(SkObjectParser::BitmapToString(bitmap));
if (src) {
@@ -346,11 +346,11 @@ SkDrawBitmapRectCommand::SkDrawBitmapRectCommand(const SkBitmap& bitmap, const S
if (paint) {
fInfo.push(SkObjectParser::PaintToString(*paint));
}
- fInfo.push(SkObjectParser::IntToString(fFlags, "Flags: "));
+ fInfo.push(SkObjectParser::IntToString(fConstraint, "Constraint: "));
}
void SkDrawBitmapRectCommand::execute(SkCanvas* canvas) const {
- canvas->drawBitmapRectToRect(fBitmap, this->srcRect(), fDst, fPaintPtr, fFlags);
+ canvas->drawBitmapRect(fBitmap, this->srcRect(), fDst, fPaintPtr, fConstraint);
}
bool SkDrawBitmapRectCommand::render(SkCanvas* canvas) const {
« no previous file with comments | « src/utils/debugger/SkDrawCommand.h ('k') | tests/RecordDrawTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698