Skia
2D Graphics Library
SkCoverageMode.h
Go to the documentation of this file.
1 /*
2  * Copyright 2018 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 SkCoverageMode_DEFINED
9 #define SkCoverageMode_DEFINED
10 
11 #include "include/core/SkTypes.h"
12 
20 enum class SkCoverageMode {
21  kUnion, // A ∪ B A+B-A*B
22  kIntersect, // A ∩ B A*B
23  kDifference, // A - B A*(1-B)
24  kReverseDifference, // B - A B*(1-A)
25  kXor, // A ⊕ B A+B-2*A*B
26 
27  kLast = kXor,
28 };
29 
30 #endif
SkTypes.h
SkCoverageMode::kReverseDifference
@ kReverseDifference
SkCoverageMode
SkCoverageMode
Describes geometric operations (ala SkRegion::Op) that can be applied to coverage bytes.
Definition: SkCoverageMode.h:20
SkBlendMode::kXor
@ kXor
r = s*(1-da) + d*(1-sa)
SkCoverageMode::kIntersect
@ kIntersect
SkCoverageMode::kDifference
@ kDifference
SkCoverageMode::kUnion
@ kUnion
SkCoverageMode::kLast
@ kLast