OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 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 #include "SkBigPicture.h" | 8 #include "SkBigPicture.h" |
9 #include "SkCanvasPriv.h" | 9 #include "SkCanvasPriv.h" |
10 #include "SkPatchUtils.h" | 10 #include "SkPatchUtils.h" |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 void SkRecorder::onDrawImageRect(const SkImage* image, const SkRect* src, const
SkRect& dst, | 233 void SkRecorder::onDrawImageRect(const SkImage* image, const SkRect* src, const
SkRect& dst, |
234 const SkPaint* paint, SrcRectConstraint constra
int) { | 234 const SkPaint* paint, SrcRectConstraint constra
int) { |
235 APPEND(DrawImageRect, this->copy(paint), image, this->copy(src), dst, constr
aint); | 235 APPEND(DrawImageRect, this->copy(paint), image, this->copy(src), dst, constr
aint); |
236 } | 236 } |
237 | 237 |
238 void SkRecorder::onDrawImageNine(const SkImage* image, const SkIRect& center, | 238 void SkRecorder::onDrawImageNine(const SkImage* image, const SkIRect& center, |
239 const SkRect& dst, const SkPaint* paint) { | 239 const SkRect& dst, const SkPaint* paint) { |
240 APPEND(DrawImageNine, this->copy(paint), image, center, dst); | 240 APPEND(DrawImageNine, this->copy(paint), image, center, dst); |
241 } | 241 } |
242 | 242 |
243 void SkRecorder::onDrawSprite(const SkBitmap& bitmap, int left, int top, const S
kPaint* paint) { | |
244 APPEND(DrawSprite, this->copy(paint), bitmap, left, top); | |
245 } | |
246 | |
247 void SkRecorder::onDrawText(const void* text, size_t byteLength, | 243 void SkRecorder::onDrawText(const void* text, size_t byteLength, |
248 SkScalar x, SkScalar y, const SkPaint& paint) { | 244 SkScalar x, SkScalar y, const SkPaint& paint) { |
249 APPEND(DrawText, | 245 APPEND(DrawText, |
250 paint, this->copy((const char*)text, byteLength), byteLength, x, y); | 246 paint, this->copy((const char*)text, byteLength), byteLength, x, y); |
251 } | 247 } |
252 | 248 |
253 void SkRecorder::onDrawPosText(const void* text, size_t byteLength, | 249 void SkRecorder::onDrawPosText(const void* text, size_t byteLength, |
254 const SkPoint pos[], const SkPaint& paint) { | 250 const SkPoint pos[], const SkPaint& paint) { |
255 const int points = paint.countText(text, byteLength); | 251 const int points = paint.countText(text, byteLength); |
256 APPEND(DrawPosText, | 252 APPEND(DrawPosText, |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
375 INHERITED(onClipPath, path, op, edgeStyle); | 371 INHERITED(onClipPath, path, op, edgeStyle); |
376 SkRecords::RegionOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle); | 372 SkRecords::RegionOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle); |
377 APPEND(ClipPath, this->devBounds(), path, opAA); | 373 APPEND(ClipPath, this->devBounds(), path, opAA); |
378 } | 374 } |
379 | 375 |
380 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) { | 376 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) { |
381 INHERITED(onClipRegion, deviceRgn, op); | 377 INHERITED(onClipRegion, deviceRgn, op); |
382 APPEND(ClipRegion, this->devBounds(), deviceRgn, op); | 378 APPEND(ClipRegion, this->devBounds(), deviceRgn, op); |
383 } | 379 } |
384 | 380 |
OLD | NEW |