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

Side by Side Diff: include/core/SkDevice.h

Issue 2277053002: Add drawRegion() API to SkCanvas (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Added shader to test 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright 2010 The Android Open Source Project 2 * Copyright 2010 The Android Open Source Project
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 #ifndef SkDevice_DEFINED 8 #ifndef SkDevice_DEFINED
9 #define SkDevice_DEFINED 9 #define SkDevice_DEFINED
10 10
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 /** These are called inside the per-device-layer loop for each draw call. 152 /** These are called inside the per-device-layer loop for each draw call.
153 When these are called, we have already applied any saveLayer operations, 153 When these are called, we have already applied any saveLayer operations,
154 and are handling any looping from the paint, and any effects from the 154 and are handling any looping from the paint, and any effects from the
155 DrawFilter. 155 DrawFilter.
156 */ 156 */
157 virtual void drawPaint(const SkDraw&, const SkPaint& paint) = 0; 157 virtual void drawPaint(const SkDraw&, const SkPaint& paint) = 0;
158 virtual void drawPoints(const SkDraw&, SkCanvas::PointMode mode, size_t coun t, 158 virtual void drawPoints(const SkDraw&, SkCanvas::PointMode mode, size_t coun t,
159 const SkPoint[], const SkPaint& paint) = 0; 159 const SkPoint[], const SkPaint& paint) = 0;
160 virtual void drawRect(const SkDraw&, const SkRect& r, 160 virtual void drawRect(const SkDraw&, const SkRect& r,
161 const SkPaint& paint) = 0; 161 const SkPaint& paint) = 0;
162 virtual void drawRegion(const SkDraw&, const SkRegion& r,
163 const SkPaint& paint);
162 virtual void drawOval(const SkDraw&, const SkRect& oval, 164 virtual void drawOval(const SkDraw&, const SkRect& oval,
163 const SkPaint& paint) = 0; 165 const SkPaint& paint) = 0;
164 /** By the time this is called we know that abs(sweepAngle) is in the range [0, 360). */ 166 /** By the time this is called we know that abs(sweepAngle) is in the range [0, 360). */
165 virtual void drawArc(const SkDraw&, const SkRect& oval, SkScalar startAngle, 167 virtual void drawArc(const SkDraw&, const SkRect& oval, SkScalar startAngle,
166 SkScalar sweepAngle, bool useCenter, const SkPaint& pai nt); 168 SkScalar sweepAngle, bool useCenter, const SkPaint& pai nt);
167 virtual void drawRRect(const SkDraw&, const SkRRect& rr, 169 virtual void drawRRect(const SkDraw&, const SkRRect& rr,
168 const SkPaint& paint) = 0; 170 const SkPaint& paint) = 0;
169 171
170 // Default impl calls drawPath() 172 // Default impl calls drawPath()
171 virtual void drawDRRect(const SkDraw&, const SkRRect& outer, 173 virtual void drawDRRect(const SkDraw&, const SkRRect& outer,
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 const SkSurfaceProps fSurfaceProps; 384 const SkSurfaceProps fSurfaceProps;
383 385
384 #ifdef SK_SUPPORT_LEGACY_ACCESSBITMAP 386 #ifdef SK_SUPPORT_LEGACY_ACCESSBITMAP
385 SkBitmap fLegacyBitmap; 387 SkBitmap fLegacyBitmap;
386 #endif 388 #endif
387 389
388 typedef SkRefCnt INHERITED; 390 typedef SkRefCnt INHERITED;
389 }; 391 };
390 392
391 #endif 393 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698