| 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 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 220 #endif | 220 #endif |
| 221 } | 221 } |
| 222 | 222 |
| 223 void SkRecorder::onDrawImage(const SkImage* image, SkScalar left, SkScalar top, | 223 void SkRecorder::onDrawImage(const SkImage* image, SkScalar left, SkScalar top, |
| 224 const SkPaint* paint) { | 224 const SkPaint* paint) { |
| 225 APPEND(DrawImage, this->copy(paint), image, left, top); | 225 APPEND(DrawImage, this->copy(paint), image, left, top); |
| 226 } | 226 } |
| 227 | 227 |
| 228 void SkRecorder::onDrawImageRect(const SkImage* image, const SkRect* src, | 228 void SkRecorder::onDrawImageRect(const SkImage* image, const SkRect* src, |
| 229 const SkRect& dst, | 229 const SkRect& dst, |
| 230 const SkPaint* paint) { | 230 const SkPaint* paint SRC_RECT_CONSTRAINT_PARAM(
constraint)) { |
| 231 APPEND(DrawImageRect, this->copy(paint), image, this->copy(src), dst); | 231 #ifdef SK_SUPPORT_LEGACY_ONDRAWIMAGERECT |
| 232 SrcRectConstraint constraint = kStrict_SrcRectConstraint; |
| 233 #endif |
| 234 APPEND(DrawImageRect, this->copy(paint), image, this->copy(src), dst, constr
aint); |
| 232 } | 235 } |
| 233 | 236 |
| 234 void SkRecorder::onDrawImageNine(const SkImage* image, const SkIRect& center, | 237 void SkRecorder::onDrawImageNine(const SkImage* image, const SkIRect& center, |
| 235 const SkRect& dst, const SkPaint* paint) { | 238 const SkRect& dst, const SkPaint* paint) { |
| 236 APPEND(DrawImageNine, this->copy(paint), image, center, dst); | 239 APPEND(DrawImageNine, this->copy(paint), image, center, dst); |
| 237 } | 240 } |
| 238 | 241 |
| 239 void SkRecorder::onDrawSprite(const SkBitmap& bitmap, int left, int top, const S
kPaint* paint) { | 242 void SkRecorder::onDrawSprite(const SkBitmap& bitmap, int left, int top, const S
kPaint* paint) { |
| 240 APPEND(DrawSprite, this->copy(paint), bitmap, left, top); | 243 APPEND(DrawSprite, this->copy(paint), bitmap, left, top); |
| 241 } | 244 } |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 376 INHERITED(onClipPath, path, op, edgeStyle); | 379 INHERITED(onClipPath, path, op, edgeStyle); |
| 377 SkRecords::RegionOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle); | 380 SkRecords::RegionOpAndAA opAA(op, kSoft_ClipEdgeStyle == edgeStyle); |
| 378 APPEND(ClipPath, this->devBounds(), path, opAA); | 381 APPEND(ClipPath, this->devBounds(), path, opAA); |
| 379 } | 382 } |
| 380 | 383 |
| 381 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) { | 384 void SkRecorder::onClipRegion(const SkRegion& deviceRgn, SkRegion::Op op) { |
| 382 INHERITED(onClipRegion, deviceRgn, op); | 385 INHERITED(onClipRegion, deviceRgn, op); |
| 383 APPEND(ClipRegion, this->devBounds(), deviceRgn, op); | 386 APPEND(ClipRegion, this->devBounds(), deviceRgn, op); |
| 384 } | 387 } |
| 385 | 388 |
| OLD | NEW |