SkPath is a class in the Skia library that holds a geometric path composed of points, lines, quadratic and cubic curves, rectangles, and arcs. The isInverseFillType method is a member function of the SkPath class that returns true if the fill type of the path is set to inverse-even-odd or inverse-non-zero, false otherwise.
Code example 1:
SkPath path; path.addRect(SkRect::MakeLTRB(100, 100, 200, 200)); path.setFillType(SkPathFillType::kInverseEvenOdd); bool isInverse = path.isInverseFillType(); // isInverse should be true.
In this example, a rectangle is added to the path and the fill type is set to inverse-even-odd. The isInverseFillType method is then called and the result is stored in the isInverse variable. Since the fill type is set to inverse-even-odd, the method should return true.
Code example 2:
SkPath path; path.addCircle(0, 0, 100); path.setFillType(SkPathFillType::kEvenOdd); bool isInverse = path.isInverseFillType(); // isInverse should be false.
In this example, a circle is added to the path and the fill type is set to even-odd. The isInverseFillType method is then called and the result is stored in the isInverse variable. Since the fill type is set to even-odd, the method should return false.
The SkPath class is part of the Skia library, which is an open-source cross-platform graphics engine for 2D and 3D graphics. It can be used in C++ projects on various operating systems including Windows, macOS, Linux, and Android.
C++ (Cpp) SkPath::isInverseFillType - 30 examples found. These are the top rated real world C++ (Cpp) examples of SkPath::isInverseFillType extracted from open source projects. You can rate examples to help us improve the quality of examples.