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

Unified Diff: src/core/SkLiteDL.h

Issue 2315283002: SkLiteDL: drawAsLayer() (Closed)
Patch Set: Created 4 years, 3 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 | « no previous file | src/core/SkLiteDL.cpp » ('j') | src/core/SkLiteDL.cpp » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkLiteDL.h
diff --git a/src/core/SkLiteDL.h b/src/core/SkLiteDL.h
index 9dd1568ddf778076b07b0e5c5fed518473058734..4f045e9458bddb90c3d6389becf01b594eed5bee 100644
--- a/src/core/SkLiteDL.h
+++ b/src/core/SkLiteDL.h
@@ -27,6 +27,20 @@ public:
void setDrawFilter(SkDrawFilter*);
#endif
+ // Draws as if...
+ // SkPaint p;
+ // p.setColorFilter(cf);
+ // p.setXfermode(xfer);
+ // p.setAlpha(alpha);
+ // SkRect bounds = this->getBounds();
+ // c->saveLayer(&bounds, &p);
+ // this->draw(c, matrix);
+ // c->restore();
+ void drawAsLayer(SkCanvas* c, const SkMatrix* matrix
djsollen 2016/09/07 14:31:36 yep, though in my current case matrix will always
reed1 2016/09/07 15:29:55 drawPicture has nearly this signature already: ca
mtklein 2016/09/08 15:20:54 sgtm, ptal
+ , SkColorFilter* cf
+ , SkXfermode* xfer
+ , U8CPU alpha);
+
void save();
void saveLayer(const SkRect*, const SkPaint*, const SkImageFilter*, SkCanvas::SaveLayerFlags);
void restore();
« no previous file with comments | « no previous file | src/core/SkLiteDL.cpp » ('j') | src/core/SkLiteDL.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698