Flutter Engine
 
Loading...
Searching...
No Matches
path_builder.h
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef FLUTTER_IMPELLER_TOOLKIT_INTEROP_PATH_BUILDER_H_
6#define FLUTTER_IMPELLER_TOOLKIT_INTEROP_PATH_BUILDER_H_
7
8#include "flutter/third_party/skia/include/core/SkPathBuilder.h"
16
17namespace impeller::interop {
18
19class PathBuilder final
20 : public Object<PathBuilder,
21 IMPELLER_INTERNAL_HANDLE_NAME(ImpellerPathBuilder)> {
22 public:
24
26
27 PathBuilder(const PathBuilder&) = delete;
28
30
31 void MoveTo(const Point& point);
32
33 void LineTo(const Point& location);
34
35 void QuadraticCurveTo(const Point& control_point, const Point& end_point);
36
37 void CubicCurveTo(const Point& control_point_1,
38 const Point& control_point_2,
39 const Point& end_point);
40
41 void AddRect(const Rect& rect);
42
43 void AddArc(const Rect& oval_bounds, Degrees start_angle, Degrees end_angle);
44
45 void AddOval(const Rect& oval_bounds);
46
47 void AddRoundedRect(const Rect& rect, const RoundingRadii& radii);
48
49 void Close();
50
52
54
55 private:
56 SkPathBuilder builder_;
57};
58
59} // namespace impeller::interop
60
61#endif // FLUTTER_IMPELLER_TOOLKIT_INTEROP_PATH_BUILDER_H_
ScopedObject< Path > CopyPath(FillType fill)
void AddArc(const Rect &oval_bounds, Degrees start_angle, Degrees end_angle)
void MoveTo(const Point &point)
void LineTo(const Point &location)
void AddOval(const Rect &oval_bounds)
void AddRoundedRect(const Rect &rect, const RoundingRadii &radii)
PathBuilder & operator=(const PathBuilder &)=delete
void QuadraticCurveTo(const Point &control_point, const Point &end_point)
void CubicCurveTo(const Point &control_point_1, const Point &control_point_2, const Point &end_point)
ScopedObject< Path > TakePath(FillType fill)
PathBuilder(const PathBuilder &)=delete
void AddRect(const Rect &rect)