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

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

Issue 23484007: call drawRect to try GrAARectRenderer if the path is a rect (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: check for inverse fill Created 7 years, 2 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 | Annotate | Revision Log
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 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
182 virtual void beginCommentGroup(const char* description) SK_OVERRIDE; 182 virtual void beginCommentGroup(const char* description) SK_OVERRIDE;
183 183
184 virtual void addComment(const char* kywd, const char* value) SK_OVERRIDE; 184 virtual void addComment(const char* kywd, const char* value) SK_OVERRIDE;
185 185
186 virtual void endCommentGroup() SK_OVERRIDE; 186 virtual void endCommentGroup() SK_OVERRIDE;
187 187
188 virtual void drawOval(const SkRect& oval, const SkPaint&) SK_OVERRIDE; 188 virtual void drawOval(const SkRect& oval, const SkPaint&) SK_OVERRIDE;
189 189
190 virtual void drawPaint(const SkPaint& paint) SK_OVERRIDE; 190 virtual void drawPaint(const SkPaint& paint) SK_OVERRIDE;
191 191
192 virtual void drawPath(const SkPath& path, const SkPaint&) SK_OVERRIDE;
193
194 virtual void drawPicture(SkPicture& picture) SK_OVERRIDE; 192 virtual void drawPicture(SkPicture& picture) SK_OVERRIDE;
195 193
196 virtual void drawPoints(PointMode, size_t count, const SkPoint pts[], 194 virtual void drawPoints(PointMode, size_t count, const SkPoint pts[],
197 const SkPaint&) SK_OVERRIDE; 195 const SkPaint&) SK_OVERRIDE;
198 196
199 virtual void drawPosText(const void* text, size_t byteLength, 197 virtual void drawPosText(const void* text, size_t byteLength,
200 const SkPoint pos[], const SkPaint&) SK_OVERRIDE; 198 const SkPoint pos[], const SkPaint&) SK_OVERRIDE;
201 199
202 virtual void drawPosTextH(const void* text, size_t byteLength, 200 virtual void drawPosTextH(const void* text, size_t byteLength,
203 const SkScalar xpos[], SkScalar constY, 201 const SkScalar xpos[], SkScalar constY,
204 const SkPaint&) SK_OVERRIDE; 202 const SkPaint&) SK_OVERRIDE;
205 203
206 virtual void drawRect(const SkRect& rect, const SkPaint&) SK_OVERRIDE;
207
208 virtual void drawRRect(const SkRRect& rrect, const SkPaint& paint) SK_OVERRI DE; 204 virtual void drawRRect(const SkRRect& rrect, const SkPaint& paint) SK_OVERRI DE;
209 205
210 virtual void drawSprite(const SkBitmap&, int left, int top, 206 virtual void drawSprite(const SkBitmap&, int left, int top,
211 const SkPaint*) SK_OVERRIDE; 207 const SkPaint*) SK_OVERRIDE;
212 208
213 virtual void drawText(const void* text, size_t byteLength, SkScalar x, 209 virtual void drawText(const void* text, size_t byteLength, SkScalar x,
214 SkScalar y, const SkPaint&) SK_OVERRIDE; 210 SkScalar y, const SkPaint&) SK_OVERRIDE;
215 211
216 virtual void drawTextOnPath(const void* text, size_t byteLength, 212 virtual void drawTextOnPath(const void* text, size_t byteLength,
217 const SkPath& path, const SkMatrix* matrix, 213 const SkPath& path, const SkMatrix* matrix,
(...skipping 17 matching lines...) Expand all
235 231
236 virtual void setMatrix(const SkMatrix& matrix) SK_OVERRIDE; 232 virtual void setMatrix(const SkMatrix& matrix) SK_OVERRIDE;
237 233
238 virtual bool skew(SkScalar sx, SkScalar sy) SK_OVERRIDE; 234 virtual bool skew(SkScalar sx, SkScalar sy) SK_OVERRIDE;
239 235
240 virtual bool translate(SkScalar dx, SkScalar dy) SK_OVERRIDE; 236 virtual bool translate(SkScalar dx, SkScalar dy) SK_OVERRIDE;
241 237
242 static const int kVizImageHeight = 256; 238 static const int kVizImageHeight = 256;
243 static const int kVizImageWidth = 256; 239 static const int kVizImageWidth = 256;
244 240
241 protected:
242 virtual void onDrawRect(const SkRect& rect, const SkPaint&) SK_OVERRIDE;
243
244 virtual void onDrawPath(const SkPath& path, const SkPaint&) SK_OVERRIDE;
245
245 private: 246 private:
246 SkTDArray<SkDrawCommand*> fCommandVector; 247 SkTDArray<SkDrawCommand*> fCommandVector;
247 int fHeight; 248 int fHeight;
248 int fWidth; 249 int fWidth;
249 SkBitmap fBm; 250 SkBitmap fBm;
250 bool fFilter; 251 bool fFilter;
251 int fIndex; 252 int fIndex;
252 SkMatrix fUserMatrix; 253 SkMatrix fUserMatrix;
253 SkMatrix fMatrix; 254 SkMatrix fMatrix;
254 SkIRect fClip; 255 SkIRect fClip;
(...skipping 21 matching lines...) Expand all
276 /** 277 /**
277 Applies any panning and zooming the user has specified before 278 Applies any panning and zooming the user has specified before
278 drawing anything else into the canvas. 279 drawing anything else into the canvas.
279 */ 280 */
280 void applyUserTransform(SkCanvas* canvas); 281 void applyUserTransform(SkCanvas* canvas);
281 282
282 typedef SkCanvas INHERITED; 283 typedef SkCanvas INHERITED;
283 }; 284 };
284 285
285 #endif 286 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698