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

Side by Side Diff: src/core/SkRecordDraw.cpp

Issue 741093002: SkRecord: Pack SkRegion::Op and AA bit together. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: MSVC, your whims are seemingly arbitrary. Created 6 years, 1 month 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 unified diff | Download patch
« no previous file with comments | « no previous file | src/core/SkRecorder.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkLayerInfo.h" 8 #include "SkLayerInfo.h"
9 #include "SkRecordDraw.h" 9 #include "SkRecordDraw.h"
10 #include "SkPatchUtils.h" 10 #include "SkPatchUtils.h"
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 79
80 #define DRAW(T, call) template <> void Draw::draw(const T& r) { fCanvas->call; } 80 #define DRAW(T, call) template <> void Draw::draw(const T& r) { fCanvas->call; }
81 DRAW(Restore, restore()); 81 DRAW(Restore, restore());
82 DRAW(Save, save()); 82 DRAW(Save, save());
83 DRAW(SaveLayer, saveLayer(r.bounds, r.paint, r.flags)); 83 DRAW(SaveLayer, saveLayer(r.bounds, r.paint, r.flags));
84 DRAW(PopCull, popCull()); 84 DRAW(PopCull, popCull());
85 DRAW(PushCull, pushCull(r.rect)); 85 DRAW(PushCull, pushCull(r.rect));
86 DRAW(Clear, clear(r.color)); 86 DRAW(Clear, clear(r.color));
87 DRAW(SetMatrix, setMatrix(SkMatrix::Concat(fInitialCTM, r.matrix))); 87 DRAW(SetMatrix, setMatrix(SkMatrix::Concat(fInitialCTM, r.matrix)));
88 88
89 DRAW(ClipPath, clipPath(r.path, r.op, r.doAA)); 89 DRAW(ClipPath, clipPath(r.path, r.opAA.op, r.opAA.aa));
90 DRAW(ClipRRect, clipRRect(r.rrect, r.op, r.doAA)); 90 DRAW(ClipRRect, clipRRect(r.rrect, r.opAA.op, r.opAA.aa));
91 DRAW(ClipRect, clipRect(r.rect, r.op, r.doAA)); 91 DRAW(ClipRect, clipRect(r.rect, r.opAA.op, r.opAA.aa));
92 DRAW(ClipRegion, clipRegion(r.region, r.op)); 92 DRAW(ClipRegion, clipRegion(r.region, r.op));
93 93
94 DRAW(BeginCommentGroup, beginCommentGroup(r.description)); 94 DRAW(BeginCommentGroup, beginCommentGroup(r.description));
95 DRAW(AddComment, addComment(r.key, r.value)); 95 DRAW(AddComment, addComment(r.key, r.value));
96 DRAW(EndCommentGroup, endCommentGroup()); 96 DRAW(EndCommentGroup, endCommentGroup());
97 97
98 DRAW(DrawBitmap, drawBitmap(shallow_copy(r.bitmap), r.left, r.top, r.paint)); 98 DRAW(DrawBitmap, drawBitmap(shallow_copy(r.bitmap), r.left, r.top, r.paint));
99 DRAW(DrawBitmapMatrix, drawBitmapMatrix(shallow_copy(r.bitmap), r.matrix, r.pain t)); 99 DRAW(DrawBitmapMatrix, drawBitmapMatrix(shallow_copy(r.bitmap), r.matrix, r.pain t));
100 DRAW(DrawBitmapNine, drawBitmapNine(shallow_copy(r.bitmap), r.center, r.dst, r.p aint)); 100 DRAW(DrawBitmapNine, drawBitmapNine(shallow_copy(r.bitmap), r.center, r.dst, r.p aint));
101 DRAW(DrawBitmapRectToRect, 101 DRAW(DrawBitmapRectToRect,
(...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 SkRecords::CollectLayers visitor(cullRect, record, data); 754 SkRecords::CollectLayers visitor(cullRect, record, data);
755 755
756 for (unsigned curOp = 0; curOp < record.count(); curOp++) { 756 for (unsigned curOp = 0; curOp < record.count(); curOp++) {
757 visitor.setCurrentOp(curOp); 757 visitor.setCurrentOp(curOp);
758 record.visit<void>(curOp, visitor); 758 record.visit<void>(curOp, visitor);
759 } 759 }
760 760
761 visitor.cleanUp(bbh); 761 visitor.cleanUp(bbh);
762 } 762 }
763 763
OLDNEW
« no previous file with comments | « no previous file | src/core/SkRecorder.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698