Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(160)

Side by Side Diff: tests/ImageFilterTest.cpp

Issue 1037793002: C++11 override should now be supported by all of {bots,Chrome,Android,Mozilla} (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: git cl web Created 5 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « tests/ImageDecodingTest.cpp ('k') | tests/LayerDrawLooperTest.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 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 "SkBitmap.h" 8 #include "SkBitmap.h"
9 #include "SkBitmapDevice.h" 9 #include "SkBitmapDevice.h"
10 #include "SkBitmapSource.h" 10 #include "SkBitmapSource.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 namespace { 44 namespace {
45 45
46 class MatrixTestImageFilter : public SkImageFilter { 46 class MatrixTestImageFilter : public SkImageFilter {
47 public: 47 public:
48 MatrixTestImageFilter(skiatest::Reporter* reporter, const SkMatrix& expected Matrix) 48 MatrixTestImageFilter(skiatest::Reporter* reporter, const SkMatrix& expected Matrix)
49 : SkImageFilter(0, NULL), fReporter(reporter), fExpectedMatrix(expectedMat rix) { 49 : SkImageFilter(0, NULL), fReporter(reporter), fExpectedMatrix(expectedMat rix) {
50 } 50 }
51 51
52 virtual bool onFilterImage(Proxy*, const SkBitmap& src, const Context& ctx, 52 virtual bool onFilterImage(Proxy*, const SkBitmap& src, const Context& ctx,
53 SkBitmap* result, SkIPoint* offset) const SK_OVER RIDE { 53 SkBitmap* result, SkIPoint* offset) const overrid e {
54 REPORTER_ASSERT(fReporter, ctx.ctm() == fExpectedMatrix); 54 REPORTER_ASSERT(fReporter, ctx.ctm() == fExpectedMatrix);
55 return true; 55 return true;
56 } 56 }
57 57
58 SK_TO_STRING_OVERRIDE() 58 SK_TO_STRING_OVERRIDE()
59 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(MatrixTestImageFilter) 59 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(MatrixTestImageFilter)
60 60
61 protected: 61 protected:
62 void flatten(SkWriteBuffer& buffer) const SK_OVERRIDE { 62 void flatten(SkWriteBuffer& buffer) const override {
63 this->INHERITED::flatten(buffer); 63 this->INHERITED::flatten(buffer);
64 buffer.writeFunctionPtr(fReporter); 64 buffer.writeFunctionPtr(fReporter);
65 buffer.writeMatrix(fExpectedMatrix); 65 buffer.writeMatrix(fExpectedMatrix);
66 } 66 }
67 67
68 private: 68 private:
69 skiatest::Reporter* fReporter; 69 skiatest::Reporter* fReporter;
70 SkMatrix fExpectedMatrix; 70 SkMatrix fExpectedMatrix;
71 71
72 typedef SkImageFilter INHERITED; 72 typedef SkImageFilter INHERITED;
(...skipping 1099 matching lines...) Expand 10 before | Expand all | Expand 10 after
1172 DEF_GPUTEST(TestNegativeBlurSigmaGPU, reporter, factory) { 1172 DEF_GPUTEST(TestNegativeBlurSigmaGPU, reporter, factory) {
1173 GrContext* context = factory->get(static_cast<GrContextFactory::GLContextTyp e>(0)); 1173 GrContext* context = factory->get(static_cast<GrContextFactory::GLContextTyp e>(0));
1174 SkAutoTUnref<SkGpuDevice> device(SkGpuDevice::Create(context, 1174 SkAutoTUnref<SkGpuDevice> device(SkGpuDevice::Create(context,
1175 SkSurface::kNo_Budgeted , 1175 SkSurface::kNo_Budgeted ,
1176 SkImageInfo::MakeN32Pre mul(1, 1), 1176 SkImageInfo::MakeN32Pre mul(1, 1),
1177 0, 1177 0,
1178 &gProps)); 1178 &gProps));
1179 test_negative_blur_sigma(device, reporter); 1179 test_negative_blur_sigma(device, reporter);
1180 } 1180 }
1181 #endif 1181 #endif
OLDNEW
« no previous file with comments | « tests/ImageDecodingTest.cpp ('k') | tests/LayerDrawLooperTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698