2 * Copyright 2021 Google LLC
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
8 #ifndef SkBlenders_DEFINED
9 #define SkBlenders_DEFINED
11 #include "include/core/SkBlender.h"
13 class SK_API SkBlenders {
16 * Create a blender that implements the following:
17 * k1 * src * dst + k2 * src + k3 * dst + k4
18 * @param k1, k2, k3, k4 The four coefficients.
19 * @param enforcePMColor If true, the RGB channels will be clamped to the calculated alpha.
21 static sk_sp<SkBlender> Arithmetic(float k1, float k2, float k3, float k4, bool enforcePremul);
24 SkBlenders() = delete;