| OLD | NEW |
| 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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 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 SK_OVER
RIDE { |
| 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 virtual void flatten(SkWriteBuffer& buffer) const SK_OVERRIDE { | 62 void flatten(SkWriteBuffer& buffer) const SK_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 1027 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1100 | 1100 |
| 1101 DEF_GPUTEST(TestNegativeBlurSigmaGPU, reporter, factory) { | 1101 DEF_GPUTEST(TestNegativeBlurSigmaGPU, reporter, factory) { |
| 1102 GrContext* context = factory->get(static_cast<GrContextFactory::GLContextTyp
e>(0)); | 1102 GrContext* context = factory->get(static_cast<GrContextFactory::GLContextTyp
e>(0)); |
| 1103 SkAutoTUnref<SkGpuDevice> device(SkGpuDevice::Create(context, | 1103 SkAutoTUnref<SkGpuDevice> device(SkGpuDevice::Create(context, |
| 1104 SkImageInfo::MakeN32Pre
mul(1, 1), | 1104 SkImageInfo::MakeN32Pre
mul(1, 1), |
| 1105 gProps, | 1105 gProps, |
| 1106 0)); | 1106 0)); |
| 1107 test_negative_blur_sigma(device, reporter); | 1107 test_negative_blur_sigma(device, reporter); |
| 1108 } | 1108 } |
| 1109 #endif | 1109 #endif |
| OLD | NEW |