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

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

Issue 835913002: Revert of move remaining virtual draw methods to onDraw (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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 | « src/utils/SkProxyCanvas.cpp ('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 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 fUserMatrix = matrix; 141 fUserMatrix = matrix;
142 fDrawNeedsReset = true; 142 fDrawNeedsReset = true;
143 } 143 }
144 144
145 SkString clipStackData() const { return fClipStackData; } 145 SkString clipStackData() const { return fClipStackData; }
146 146
147 //////////////////////////////////////////////////////////////////////////////// 147 ////////////////////////////////////////////////////////////////////////////////
148 // Inherited from SkCanvas 148 // Inherited from SkCanvas
149 //////////////////////////////////////////////////////////////////////////////// 149 ////////////////////////////////////////////////////////////////////////////////
150 150
151 virtual void drawBitmap(const SkBitmap&, SkScalar left, SkScalar top,
152 const SkPaint*) SK_OVERRIDE;
153
154 virtual void drawBitmapRectToRect(const SkBitmap&, const SkRect* src,
155 const SkRect& dst, const SkPaint* paint,
156 DrawBitmapRectFlags flags) SK_OVERRIDE;
157
158 virtual void drawBitmapNine(const SkBitmap& bitmap, const SkIRect& center,
159 const SkRect& dst, const SkPaint*) SK_OVERRIDE;
160
151 virtual void beginCommentGroup(const char* description) SK_OVERRIDE; 161 virtual void beginCommentGroup(const char* description) SK_OVERRIDE;
162
152 virtual void addComment(const char* kywd, const char* value) SK_OVERRIDE; 163 virtual void addComment(const char* kywd, const char* value) SK_OVERRIDE;
164
153 virtual void endCommentGroup() SK_OVERRIDE; 165 virtual void endCommentGroup() SK_OVERRIDE;
154 166
167 virtual void drawOval(const SkRect& oval, const SkPaint&) SK_OVERRIDE;
168
169 virtual void drawPaint(const SkPaint& paint) SK_OVERRIDE;
170
171 virtual void drawPath(const SkPath& path, const SkPaint&) SK_OVERRIDE;
172
173 virtual void drawPoints(PointMode, size_t count, const SkPoint pts[],
174 const SkPaint&) SK_OVERRIDE;
175
176 virtual void drawRect(const SkRect& rect, const SkPaint&) SK_OVERRIDE;
177
178 virtual void drawRRect(const SkRRect& rrect, const SkPaint& paint) SK_OVERRI DE;
179
180 virtual void drawSprite(const SkBitmap&, int left, int top,
181 const SkPaint*) SK_OVERRIDE;
182
183 virtual void drawVertices(VertexMode, int vertexCount,
184 const SkPoint vertices[], const SkPoint texs[],
185 const SkColor colors[], SkXfermode*,
186 const uint16_t indices[], int indexCount,
187 const SkPaint&) SK_OVERRIDE;
188
155 static const int kVizImageHeight = 256; 189 static const int kVizImageHeight = 256;
156 static const int kVizImageWidth = 256; 190 static const int kVizImageWidth = 256;
157 191
158 virtual bool isClipEmpty() const SK_OVERRIDE { return false; } 192 virtual bool isClipEmpty() const SK_OVERRIDE { return false; }
159 virtual bool isClipRect() const SK_OVERRIDE { return true; } 193 virtual bool isClipRect() const SK_OVERRIDE { return true; }
160 virtual bool getClipBounds(SkRect* bounds) const SK_OVERRIDE { 194 virtual bool getClipBounds(SkRect* bounds) const SK_OVERRIDE {
161 if (bounds) { 195 if (bounds) {
162 bounds->setXYWH(0, 0, 196 bounds->setXYWH(0, 0,
163 SkIntToScalar(this->imageInfo().width()), 197 SkIntToScalar(this->imageInfo().width()),
164 SkIntToScalar(this->imageInfo().height())); 198 SkIntToScalar(this->imageInfo().height()));
(...skipping 20 matching lines...) Expand all
185 const SkPaint&) SK_OVERRIDE; 219 const SkPaint&) SK_OVERRIDE;
186 virtual void onDrawPosText(const void* text, size_t byteLength, const SkPoin t pos[], 220 virtual void onDrawPosText(const void* text, size_t byteLength, const SkPoin t pos[],
187 const SkPaint&) SK_OVERRIDE; 221 const SkPaint&) SK_OVERRIDE;
188 virtual void onDrawPosTextH(const void* text, size_t byteLength, const SkSca lar xpos[], 222 virtual void onDrawPosTextH(const void* text, size_t byteLength, const SkSca lar xpos[],
189 SkScalar constY, const SkPaint&) SK_OVERRIDE; 223 SkScalar constY, const SkPaint&) SK_OVERRIDE;
190 virtual void onDrawTextOnPath(const void* text, size_t byteLength, const SkP ath& path, 224 virtual void onDrawTextOnPath(const void* text, size_t byteLength, const SkP ath& path,
191 const SkMatrix* matrix, const SkPaint&) SK_OVE RRIDE; 225 const SkMatrix* matrix, const SkPaint&) SK_OVE RRIDE;
192 virtual void onDrawTextBlob(const SkTextBlob* blob, SkScalar x, SkScalar y, 226 virtual void onDrawTextBlob(const SkTextBlob* blob, SkScalar x, SkScalar y,
193 const SkPaint& paint) SK_OVERRIDE; 227 const SkPaint& paint) SK_OVERRIDE;
194 228
195 void onDrawPaint(const SkPaint&) SK_OVERRIDE;
196 void onDrawPoints(PointMode, size_t count, const SkPoint pts[], const SkPain t&) SK_OVERRIDE;
197 void onDrawRect(const SkRect&, const SkPaint&) SK_OVERRIDE;
198 void onDrawOval(const SkRect&, const SkPaint&) SK_OVERRIDE;
199 void onDrawRRect(const SkRRect&, const SkPaint&) SK_OVERRIDE;
200 void onDrawPath(const SkPath&, const SkPaint&) SK_OVERRIDE;
201 void onDrawBitmap(const SkBitmap&, SkScalar left, SkScalar top, const SkPain t*) SK_OVERRIDE;
202 void onDrawBitmapRect(const SkBitmap&, const SkRect* src, const SkRect& dst, const SkPaint*,
203 DrawBitmapRectFlags flags) SK_OVERRIDE;
204 void onDrawImage(const SkImage*, SkScalar left, SkScalar top, const SkPaint* ) SK_OVERRIDE;
205 void onDrawImageRect(const SkImage*, const SkRect* src, const SkRect& dst,
206 const SkPaint*) SK_OVERRIDE;
207 void onDrawBitmapNine(const SkBitmap&, const SkIRect& center, const SkRect& dst,
208 const SkPaint*) SK_OVERRIDE;
209 void onDrawSprite(const SkBitmap&, int left, int top, const SkPaint*) SK_OVE RRIDE;
210 void onDrawVertices(VertexMode vmode, int vertexCount,
211 const SkPoint vertices[], const SkPoint texs[],
212 const SkColor colors[], SkXfermode* xmode,
213 const uint16_t indices[], int indexCount,
214 const SkPaint&) SK_OVERRIDE;
215
216 virtual void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) SK_OVERR IDE; 229 virtual void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) SK_OVERR IDE;
217 virtual void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) SK_OVE RRIDE; 230 virtual void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) SK_OVE RRIDE;
218 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) SK_OVERR IDE; 231 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) SK_OVERR IDE;
219 virtual void onClipRegion(const SkRegion& region, SkRegion::Op) SK_OVERRIDE; 232 virtual void onClipRegion(const SkRegion& region, SkRegion::Op) SK_OVERRIDE;
220 233
221 virtual void onDrawPicture(const SkPicture*, const SkMatrix*, const SkPaint* ) SK_OVERRIDE; 234 virtual void onDrawPicture(const SkPicture*, const SkMatrix*, const SkPaint* ) SK_OVERRIDE;
222 235
223 void markActiveCommands(int index); 236 void markActiveCommands(int index);
224 237
225 private: 238 private:
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
286 bool lastClipStackData(const SkPath& devPath); 299 bool lastClipStackData(const SkPath& devPath);
287 void outputConicPoints(const SkPoint* pts, SkScalar weight); 300 void outputConicPoints(const SkPoint* pts, SkScalar weight);
288 void outputPoints(const SkPoint* pts, int count); 301 void outputPoints(const SkPoint* pts, int count);
289 void outputPointsCommon(const SkPoint* pts, int count); 302 void outputPointsCommon(const SkPoint* pts, int count);
290 void outputScalar(SkScalar num); 303 void outputScalar(SkScalar num);
291 304
292 typedef SkCanvas INHERITED; 305 typedef SkCanvas INHERITED;
293 }; 306 };
294 307
295 #endif 308 #endif
OLDNEW
« no previous file with comments | « src/utils/SkProxyCanvas.cpp ('k') | src/utils/debugger/SkDebugCanvas.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698