1 /* 2 * Copyright 2016 Google Inc. 3 * 4 * Use of this source code is governed by a BSD-style license that can be 5 * found in the LICENSE file. 6 */ 7 8 #ifndef SkArithmeticImageFilter_DEFINED 9 #define SkArithmeticImageFilter_DEFINED 10 11 #include "SkImageFilter.h" 12 13 class SK_API SkArithmeticImageFilter { 14 public: 15 static sk_sp<SkImageFilter> Make(float k1, float k2, float k3, float k4, bool enforcePMColor, 16 sk_sp<SkImageFilter> background, 17 sk_sp<SkImageFilter> foreground, 18 const SkImageFilter::CropRect* cropRect); Make(float k1,float k2,float k3,float k4,bool enforcePMColor,sk_sp<SkImageFilter> background)19 static sk_sp<SkImageFilter> Make(float k1, float k2, float k3, float k4, bool enforcePMColor, 20 sk_sp<SkImageFilter> background) { 21 return Make(k1, k2, k3, k4, enforcePMColor, std::move(background), nullptr, nullptr); 22 } 23 24 SK_DECLARE_FLATTENABLE_REGISTRAR_GROUP(); 25 26 private: 27 SkArithmeticImageFilter(); // can't instantiate 28 }; 29 30 #endif 31