| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 SkPictureRecord_DEFINED | 8 #ifndef SkPictureRecord_DEFINED |
| 9 #define SkPictureRecord_DEFINED | 9 #define SkPictureRecord_DEFINED |
| 10 | 10 |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 sk_sp<SkSurface> onNewSurface(const SkImageInfo&, const SkSurfaceProps&) ove
rride; | 152 sk_sp<SkSurface> onNewSurface(const SkImageInfo&, const SkSurfaceProps&) ove
rride; |
| 153 bool onPeekPixels(SkPixmap*) override { return false; } | 153 bool onPeekPixels(SkPixmap*) override { return false; } |
| 154 | 154 |
| 155 void willSave() override; | 155 void willSave() override; |
| 156 SaveLayerStrategy getSaveLayerStrategy(const SaveLayerRec&) override; | 156 SaveLayerStrategy getSaveLayerStrategy(const SaveLayerRec&) override; |
| 157 void willRestore() override; | 157 void willRestore() override; |
| 158 | 158 |
| 159 void didConcat(const SkMatrix&) override; | 159 void didConcat(const SkMatrix&) override; |
| 160 void didSetMatrix(const SkMatrix&) override; | 160 void didSetMatrix(const SkMatrix&) override; |
| 161 | 161 |
| 162 #ifdef SK_EXPERIMENTAL_SHADOWING | |
| 163 void didTranslateZ(SkScalar) override; | 162 void didTranslateZ(SkScalar) override; |
| 164 #endif | |
| 165 void didTranslateZ(SkScalar); | |
| 166 #endif | |
| 167 | 163 |
| 168 void onDrawDRRect(const SkRRect&, const SkRRect&, const SkPaint&) override; | 164 void onDrawDRRect(const SkRRect&, const SkRRect&, const SkPaint&) override; |
| 169 | 165 |
| 170 void onDrawText(const void* text, size_t, SkScalar x, SkScalar y, const SkPa
int&) override; | 166 void onDrawText(const void* text, size_t, SkScalar x, SkScalar y, const SkPa
int&) override; |
| 171 void onDrawPosText(const void* text, size_t, const SkPoint pos[], const SkPa
int&) override; | 167 void onDrawPosText(const void* text, size_t, const SkPoint pos[], const SkPa
int&) override; |
| 172 void onDrawPosTextH(const void* text, size_t, const SkScalar xpos[], SkScala
r constY, | 168 void onDrawPosTextH(const void* text, size_t, const SkScalar xpos[], SkScala
r constY, |
| 173 const SkPaint&) override; | 169 const SkPaint&) override; |
| 174 void onDrawTextOnPath(const void* text, size_t byteLength, const SkPath& pat
h, | 170 void onDrawTextOnPath(const void* text, size_t byteLength, const SkPath& pat
h, |
| 175 const SkMatrix* matrix, const SkPaint&) overri
de; | 171 const SkMatrix* matrix, const SkPaint&) overri
de; |
| 176 void onDrawTextRSXform(const void* text, size_t byteLength, const SkRSXform
xform[], | 172 void onDrawTextRSXform(const void* text, size_t byteLength, const SkRSXform
xform[], |
| (...skipping 28 matching lines...) Expand all Loading... |
| 205 const SkColor colors[], SkXfermode* xmode, | 201 const SkColor colors[], SkXfermode* xmode, |
| 206 const uint16_t indices[], int indexCount, | 202 const uint16_t indices[], int indexCount, |
| 207 const SkPaint&) override; | 203 const SkPaint&) override; |
| 208 | 204 |
| 209 void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) override; | 205 void onClipRect(const SkRect&, SkRegion::Op, ClipEdgeStyle) override; |
| 210 void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) override; | 206 void onClipRRect(const SkRRect&, SkRegion::Op, ClipEdgeStyle) override; |
| 211 void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) override; | 207 void onClipPath(const SkPath&, SkRegion::Op, ClipEdgeStyle) override; |
| 212 void onClipRegion(const SkRegion&, SkRegion::Op) override; | 208 void onClipRegion(const SkRegion&, SkRegion::Op) override; |
| 213 | 209 |
| 214 void onDrawPicture(const SkPicture*, const SkMatrix*, const SkPaint*) overri
de; | 210 void onDrawPicture(const SkPicture*, const SkMatrix*, const SkPaint*) overri
de; |
| 215 | |
| 216 #ifdef SK_EXPERIMENTAL_SHADOWING | |
| 217 void onDrawShadowedPicture(const SkPicture*, | |
| 218 const SkMatrix*, | |
| 219 const SkPaint*) override; | |
| 220 #else | |
| 221 void onDrawShadowedPicture(const SkPicture*, | |
| 222 const SkMatrix*, | |
| 223 const SkPaint*); | |
| 224 #endif | |
| 225 | |
| 226 void onDrawDrawable(SkDrawable*, const SkMatrix*) override; | 211 void onDrawDrawable(SkDrawable*, const SkMatrix*) override; |
| 227 void onDrawAnnotation(const SkRect&, const char[], SkData*) override; | 212 void onDrawAnnotation(const SkRect&, const char[], SkData*) override; |
| 228 | 213 |
| 229 int addPathToHeap(const SkPath& path); // does not write to ops stream | 214 int addPathToHeap(const SkPath& path); // does not write to ops stream |
| 230 | 215 |
| 231 // These entry points allow the writing of matrices, clips, saves & | 216 // These entry points allow the writing of matrices, clips, saves & |
| 232 // restores to be deferred (e.g., if the MC state is being collapsed and | 217 // restores to be deferred (e.g., if the MC state is being collapsed and |
| 233 // only written out as needed). | 218 // only written out as needed). |
| 234 void recordConcat(const SkMatrix& matrix); | 219 void recordConcat(const SkMatrix& matrix); |
| 235 void recordTranslate(const SkMatrix& matrix); | 220 void recordTranslate(const SkMatrix& matrix); |
| (...skipping 25 matching lines...) Expand all Loading... |
| 261 SkTDArray<SkDrawable*> fDrawableRefs; | 246 SkTDArray<SkDrawable*> fDrawableRefs; |
| 262 SkTDArray<const SkTextBlob*> fTextBlobRefs; | 247 SkTDArray<const SkTextBlob*> fTextBlobRefs; |
| 263 | 248 |
| 264 uint32_t fRecordFlags; | 249 uint32_t fRecordFlags; |
| 265 int fInitialSaveCount; | 250 int fInitialSaveCount; |
| 266 | 251 |
| 267 friend class SkPictureData; // for SkPictureData's SkPictureRecord-based c
onstructor | 252 friend class SkPictureData; // for SkPictureData's SkPictureRecord-based c
onstructor |
| 268 | 253 |
| 269 typedef SkCanvas INHERITED; | 254 typedef SkCanvas INHERITED; |
| 270 }; | 255 }; |
| 256 |
| 257 #endif |
| OLD | NEW |