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

Unified Diff: include/private/SkRecords.h

Issue 2355483002: abstract name of clipping ops, to transtion to a more restricted set (Closed)
Patch Set: no need for ifdef for globals 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 | « include/gpu/GrPaint.h ('k') | include/utils/SkDumpCanvas.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/private/SkRecords.h
diff --git a/include/private/SkRecords.h b/include/private/SkRecords.h
index 2800a96b5615575ae048ac7a85c35f75c13dc056..f2cade56571c17b23e5f141b3f6771b32ffa1658 100644
--- a/include/private/SkRecords.h
+++ b/include/private/SkRecords.h
@@ -190,30 +190,30 @@ RECORD(Translate, 0,
SkScalar dy);
RECORD(TranslateZ, 0, SkScalar z);
-struct RegionOpAndAA {
- RegionOpAndAA() {}
- RegionOpAndAA(SkRegion::Op op, bool aa) : op(op), aa(aa) {}
- SkRegion::Op op : 31; // This really only needs to be 3, but there's no win today to do so.
- unsigned aa : 1; // MSVC won't pack an enum with an bool, so we call this an unsigned.
+struct ClipOpAndAA {
+ ClipOpAndAA() {}
+ ClipOpAndAA(SkCanvas::ClipOp op, bool aa) : op(op), aa(aa) {}
+ SkCanvas::ClipOp op : 31; // This really only needs to be 3, but there's no win today to do so.
+ unsigned aa : 1; // MSVC won't pack an enum with an bool, so we call this an unsigned.
};
-static_assert(sizeof(RegionOpAndAA) == 4, "RegionOpAndAASize");
+static_assert(sizeof(ClipOpAndAA) == 4, "ClipOpAndAASize");
RECORD(ClipPath, 0,
SkIRect devBounds;
PreCachedPath path;
- RegionOpAndAA opAA);
+ ClipOpAndAA opAA);
RECORD(ClipRRect, 0,
SkIRect devBounds;
SkRRect rrect;
- RegionOpAndAA opAA);
+ ClipOpAndAA opAA);
RECORD(ClipRect, 0,
SkIRect devBounds;
SkRect rect;
- RegionOpAndAA opAA);
+ ClipOpAndAA opAA);
RECORD(ClipRegion, 0,
SkIRect devBounds;
SkRegion region;
- SkRegion::Op op);
+ SkCanvas::ClipOp op);
// While not strictly required, if you have an SkPaint, it's fastest to put it first.
RECORD(DrawArc, kDraw_Tag|kHasPaint_Tag,
« no previous file with comments | « include/gpu/GrPaint.h ('k') | include/utils/SkDumpCanvas.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698