diff options
author | Matt Sarett <msarett@google.com> | 2017-04-27 20:08:39 +0000 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-04-27 20:08:45 +0000 |
commit | 0122af08f6af0dee490e1a4f35b552377d0d4753 (patch) | |
tree | dc2a227b525f067fe8c837cc8d4c5c3480cb69de /samplecode | |
parent | 4b32ab1b7cac09f42b0867f6c63cd8656dd9918d (diff) |
Revert "Delete copyTo(Allocator), hide copyTo() behind flag"
This reverts commit d4a338f4d0a0cdc08d7d3668931c60997f0fa971.
Reason for revert: Looks like I missed something I was supposed to delete in Android.
Original change's description:
> Delete copyTo(Allocator), hide copyTo() behind flag
>
> Replace uses of copyTo() in Skia.
>
> Bug: skia:6464
> Change-Id: I921dc53a1c29a5176d18f05741f7c0b5a008e548
> Reviewed-on: https://skia-review.googlesource.com/14502
> Commit-Queue: Matt Sarett <msarett@google.com>
> Reviewed-by: Mike Reed <reed@google.com>
>
TBR=msarett@google.com,reed@google.com
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
Change-Id: I4d252940cc6a2462b030007055ea6c229471fc6e
Reviewed-on: https://skia-review.googlesource.com/14602
Reviewed-by: Matt Sarett <msarett@google.com>
Commit-Queue: Matt Sarett <msarett@google.com>
Diffstat (limited to 'samplecode')
-rw-r--r-- | samplecode/SampleDither.cpp | 3 | ||||
-rw-r--r-- | samplecode/SampleDitherBitmap.cpp | 3 | ||||
-rw-r--r-- | samplecode/SampleFilter.cpp | 6 |
3 files changed, 5 insertions, 7 deletions
diff --git a/samplecode/SampleDither.cpp b/samplecode/SampleDither.cpp index 6d91fda3ad..76ebecc25f 100644 --- a/samplecode/SampleDither.cpp +++ b/samplecode/SampleDither.cpp @@ -19,7 +19,6 @@ #include "SkColorPriv.h" #include "SkColorFilter.h" #include "SkDither.h" -#include "sk_tool_utils.h" static void draw_sweep(SkCanvas* c, int width, int height, SkScalar angle) { SkRect r; @@ -112,7 +111,7 @@ public: make_bm(&fBM); make_bm(&fBMPreDither); pre_dither(fBMPreDither); - sk_tool_utils::copy_to(&fBM16, kARGB_4444_SkColorType, fBM); + fBM.copyTo(&fBM16, kARGB_4444_SkColorType); fAngle = 0; diff --git a/samplecode/SampleDitherBitmap.cpp b/samplecode/SampleDitherBitmap.cpp index 2f3de35fd6..e5f7369ae1 100644 --- a/samplecode/SampleDitherBitmap.cpp +++ b/samplecode/SampleDitherBitmap.cpp @@ -13,7 +13,6 @@ #include "SkRegion.h" #include "SkUtils.h" #include "SkView.h" -#include "sk_tool_utils.h" static void draw_rect(SkCanvas* canvas, const SkRect& r, const SkPaint& p) { canvas->drawRect(r, p); @@ -78,7 +77,7 @@ public: DitherBitmapView() { fResult = test_pathregion(); fBM8 = make_bitmap(); - sk_tool_utils::copy_to(&fBM32, kN32_SkColorType, fBM8); + fBM8.copyTo(&fBM32, kN32_SkColorType); this->setBGColor(0xFFDDDDDD); } diff --git a/samplecode/SampleFilter.cpp b/samplecode/SampleFilter.cpp index 00f3853d4e..d12f804d19 100644 --- a/samplecode/SampleFilter.cpp +++ b/samplecode/SampleFilter.cpp @@ -78,9 +78,9 @@ public: FilterView() { make_bm(&fBM8); - sk_tool_utils::copy_to(&fBM4444, kARGB_4444_SkColorType, fBM8); - sk_tool_utils::copy_to(&fBM16, kRGB_565_SkColorType, fBM8); - sk_tool_utils::copy_to(&fBM32, kN32_SkColorType, fBM8); + fBM8.copyTo(&fBM4444, kARGB_4444_SkColorType); + fBM8.copyTo(&fBM16, kRGB_565_SkColorType); + fBM8.copyTo(&fBM32, kN32_SkColorType); this->setBGColor(0xFFDDDDDD); } |