| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 #ifndef SkDeferredCanvas_DEFINED | 8 #ifndef SkDeferredCanvas_DEFINED |
| 9 #define SkDeferredCanvas_DEFINED | 9 #define SkDeferredCanvas_DEFINED |
| 10 | 10 |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 const SkRect& dst, const SkPaint* paint, | 155 const SkRect& dst, const SkPaint* paint, |
| 156 DrawBitmapRectFlags flags) SK_OVERRIDE; | 156 DrawBitmapRectFlags flags) SK_OVERRIDE; |
| 157 | 157 |
| 158 virtual void drawBitmapMatrix(const SkBitmap& bitmap, const SkMatrix& m, | 158 virtual void drawBitmapMatrix(const SkBitmap& bitmap, const SkMatrix& m, |
| 159 const SkPaint* paint) SK_OVERRIDE; | 159 const SkPaint* paint) SK_OVERRIDE; |
| 160 virtual void drawBitmapNine(const SkBitmap& bitmap, const SkIRect& center, | 160 virtual void drawBitmapNine(const SkBitmap& bitmap, const SkIRect& center, |
| 161 const SkRect& dst, const SkPaint* paint) | 161 const SkRect& dst, const SkPaint* paint) |
| 162 SK_OVERRIDE; | 162 SK_OVERRIDE; |
| 163 virtual void drawSprite(const SkBitmap& bitmap, int left, int top, | 163 virtual void drawSprite(const SkBitmap& bitmap, int left, int top, |
| 164 const SkPaint* paint) SK_OVERRIDE; | 164 const SkPaint* paint) SK_OVERRIDE; |
| 165 virtual void drawText(const void* text, size_t byteLength, SkScalar x, |
| 166 SkScalar y, const SkPaint& paint) SK_OVERRIDE; |
| 167 virtual void drawPosText(const void* text, size_t byteLength, |
| 168 const SkPoint pos[], const SkPaint& paint) |
| 169 SK_OVERRIDE; |
| 170 virtual void drawPosTextH(const void* text, size_t byteLength, |
| 171 const SkScalar xpos[], SkScalar constY, |
| 172 const SkPaint& paint) SK_OVERRIDE; |
| 173 virtual void drawTextOnPath(const void* text, size_t byteLength, |
| 174 const SkPath& path, const SkMatrix* matrix, |
| 175 const SkPaint& paint) SK_OVERRIDE; |
| 165 virtual void drawPicture(SkPicture& picture) SK_OVERRIDE; | 176 virtual void drawPicture(SkPicture& picture) SK_OVERRIDE; |
| 166 virtual void drawVertices(VertexMode vmode, int vertexCount, | 177 virtual void drawVertices(VertexMode vmode, int vertexCount, |
| 167 const SkPoint vertices[], const SkPoint texs[], | 178 const SkPoint vertices[], const SkPoint texs[], |
| 168 const SkColor colors[], SkXfermode* xmode, | 179 const SkColor colors[], SkXfermode* xmode, |
| 169 const uint16_t indices[], int indexCount, | 180 const uint16_t indices[], int indexCount, |
| 170 const SkPaint& paint) SK_OVERRIDE; | 181 const SkPaint& paint) SK_OVERRIDE; |
| 171 virtual SkBounder* setBounder(SkBounder* bounder) SK_OVERRIDE; | 182 virtual SkBounder* setBounder(SkBounder* bounder) SK_OVERRIDE; |
| 172 virtual SkDrawFilter* setDrawFilter(SkDrawFilter* filter) SK_OVERRIDE; | 183 virtual SkDrawFilter* setDrawFilter(SkDrawFilter* filter) SK_OVERRIDE; |
| 173 | 184 |
| 174 protected: | 185 protected: |
| 175 virtual void willSave(SaveFlags) SK_OVERRIDE; | 186 virtual void willSave(SaveFlags) SK_OVERRIDE; |
| 176 virtual SaveLayerStrategy willSaveLayer(const SkRect*, const SkPaint*, SaveF
lags) SK_OVERRIDE; | 187 virtual SaveLayerStrategy willSaveLayer(const SkRect*, const SkPaint*, SaveF
lags) SK_OVERRIDE; |
| 177 virtual void willRestore() SK_OVERRIDE; | 188 virtual void willRestore() SK_OVERRIDE; |
| 178 | 189 |
| 179 virtual void didConcat(const SkMatrix&) SK_OVERRIDE; | 190 virtual void didConcat(const SkMatrix&) SK_OVERRIDE; |
| 180 virtual void didSetMatrix(const SkMatrix&) SK_OVERRIDE; | 191 virtual void didSetMatrix(const SkMatrix&) SK_OVERRIDE; |
| 181 | 192 |
| 182 virtual void onDrawDRRect(const SkRRect&, const SkRRect&, const SkPaint&) SK
_OVERRIDE; | 193 virtual void onDrawDRRect(const SkRRect&, const SkRRect&, |
| 183 virtual void onDrawText(const void* text, size_t byteLength, SkScalar x, SkS
calar y, | 194 const SkPaint&) SK_OVERRIDE; |
| 184 const SkPaint&) SK_OVERRIDE; | |
| 185 virtual void onDrawPosText(const void* text, size_t byteLength, const SkPoin
t pos[], | |
| 186 const SkPaint&) SK_OVERRIDE; | |
| 187 virtual void onDrawPosTextH(const void* text, size_t byteLength, const SkSca
lar xpos[], | |
| 188 SkScalar constY, const SkPaint&) SK_OVERRIDE; | |
| 189 virtual void onDrawTextOnPath(const void* text, size_t byteLength, const SkP
ath& path, | |
| 190 const SkMatrix* matrix, const SkPaint&) SK_OVE
RRIDE; | |
| 191 | 195 |
| 192 virtual void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) SK_OVERR
IDE; | 196 virtual void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) SK_OVERR
IDE; |
| 193 virtual void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) SK_OVE
RRIDE; | 197 virtual void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) SK_OVE
RRIDE; |
| 194 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) SK_OVERR
IDE; | 198 virtual void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) SK_OVERR
IDE; |
| 195 virtual void onClipRegion(const SkRegion&, SkRegion::Op) SK_OVERRIDE; | 199 virtual void onClipRegion(const SkRegion&, SkRegion::Op) SK_OVERRIDE; |
| 196 | 200 |
| 197 public: | 201 public: |
| 198 class NotificationClient { | 202 class NotificationClient { |
| 199 public: | 203 public: |
| 200 virtual ~NotificationClient() {} | 204 virtual ~NotificationClient() {} |
| (...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 241 void validate() const; | 245 void validate() const; |
| 242 void init(); | 246 void init(); |
| 243 bool fDeferredDrawing; | 247 bool fDeferredDrawing; |
| 244 | 248 |
| 245 friend class SkDeferredCanvasTester; // for unit testing | 249 friend class SkDeferredCanvasTester; // for unit testing |
| 246 typedef SkCanvas INHERITED; | 250 typedef SkCanvas INHERITED; |
| 247 }; | 251 }; |
| 248 | 252 |
| 249 | 253 |
| 250 #endif | 254 #endif |
| OLD | NEW |