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

Side by Side Diff: src/utils/debugger/SkDebugCanvas.h

Issue 835113002: Remove draw window size state from SkDebugCanvas (Closed) Base URL: https://skia.googlesource.com/skia.git@debugger-small-things-04-index-zero-draw
Patch Set: rebase Created 5 years, 11 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 unified diff | Download patch
« no previous file with comments | « debugger/SkDebugger.h ('k') | src/utils/debugger/SkDebugCanvas.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 /* 2 /*
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 9
10 #ifndef SKDEBUGCANVAS_H_ 10 #ifndef SKDEBUGCANVAS_H_
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 int getSize() const { 128 int getSize() const {
129 return fCommandVector.count(); 129 return fCommandVector.count();
130 } 130 }
131 131
132 /** 132 /**
133 Toggles the visibility / execution of the draw command at index i with 133 Toggles the visibility / execution of the draw command at index i with
134 the value of toggle. 134 the value of toggle.
135 */ 135 */
136 void toggleCommand(int index, bool toggle); 136 void toggleCommand(int index, bool toggle);
137 137
138 void setWindowSize(int width, int height) { fWindowSize.set(width, height); }
139
140 void setUserMatrix(SkMatrix matrix) { 138 void setUserMatrix(SkMatrix matrix) {
141 fUserMatrix = matrix; 139 fUserMatrix = matrix;
142 fDrawNeedsReset = true; 140 fDrawNeedsReset = true;
143 } 141 }
144 142
145 SkString clipStackData() const { return fClipStackData; } 143 SkString clipStackData() const { return fClipStackData; }
146 144
147 //////////////////////////////////////////////////////////////////////////////// 145 ////////////////////////////////////////////////////////////////////////////////
148 // Inherited from SkCanvas 146 // Inherited from SkCanvas
149 //////////////////////////////////////////////////////////////////////////////// 147 ////////////////////////////////////////////////////////////////////////////////
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) SK_OVERR IDE; 216 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) SK_OVERR IDE;
219 virtual void onClipRegion(const SkRegion& region, SkRegion::Op) SK_OVERRIDE; 217 virtual void onClipRegion(const SkRegion& region, SkRegion::Op) SK_OVERRIDE;
220 218
221 virtual void onDrawPicture(const SkPicture*, const SkMatrix*, const SkPaint* ) SK_OVERRIDE; 219 virtual void onDrawPicture(const SkPicture*, const SkMatrix*, const SkPaint* ) SK_OVERRIDE;
222 220
223 void markActiveCommands(int index); 221 void markActiveCommands(int index);
224 222
225 private: 223 private:
226 SkTDArray<SkDrawCommand*> fCommandVector; 224 SkTDArray<SkDrawCommand*> fCommandVector;
227 SkPicture* fPicture; 225 SkPicture* fPicture;
228 SkISize fWindowSize;
229 bool fFilter; 226 bool fFilter;
230 bool fMegaVizMode; 227 bool fMegaVizMode;
231 int fIndex; 228 int fIndex;
232 SkMatrix fUserMatrix; 229 SkMatrix fUserMatrix;
233 bool fDrawNeedsReset; // fUserMatrix has changed so the incremental draw won't work 230 bool fDrawNeedsReset; // fUserMatrix has changed so the incremental draw won't work
234 SkMatrix fMatrix; 231 SkMatrix fMatrix;
235 SkIRect fClip; 232 SkIRect fClip;
236 233
237 SkString fClipStackData; 234 SkString fClipStackData;
238 bool fCalledAddStackData; 235 bool fCalledAddStackData;
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
286 bool lastClipStackData(const SkPath& devPath); 283 bool lastClipStackData(const SkPath& devPath);
287 void outputConicPoints(const SkPoint* pts, SkScalar weight); 284 void outputConicPoints(const SkPoint* pts, SkScalar weight);
288 void outputPoints(const SkPoint* pts, int count); 285 void outputPoints(const SkPoint* pts, int count);
289 void outputPointsCommon(const SkPoint* pts, int count); 286 void outputPointsCommon(const SkPoint* pts, int count);
290 void outputScalar(SkScalar num); 287 void outputScalar(SkScalar num);
291 288
292 typedef SkCanvas INHERITED; 289 typedef SkCanvas INHERITED;
293 }; 290 };
294 291
295 #endif 292 #endif
OLDNEW
« no previous file with comments | « debugger/SkDebugger.h ('k') | src/utils/debugger/SkDebugCanvas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698