#include <path_component.h>
Public Types | |
| using | PointProc = std::function< void(const Point &point)> |
Public Member Functions | |
| ConicPathComponent () | |
| ConicPathComponent (Point ap1, Point acp, Point ap2, Scalar weight) | |
| Point | Solve (Scalar time) const |
| void | AppendPolylinePoints (Scalar scale_factor, std::vector< Point > &points) const |
| void | ToLinearPathComponents (Scalar scale_factor, const PointProc &proc) const |
| void | ToLinearPathComponents (Scalar scale, VertexWriter &writer) const |
| size_t | CountLinearPathComponents (Scalar scale) const |
| std::vector< Point > | Extrema () const |
| bool | operator== (const ConicPathComponent &other) const |
| std::optional< Vector2 > | GetStartDirection () const |
| std::optional< Vector2 > | GetEndDirection () const |
| std::array< QuadraticPathComponent, 2 > | ToQuadraticPathComponents () const |
| void | SubdivideToQuadraticPoints (std::array< Point, 5 > &points) const |
Public Attributes | |
| Point | p1 |
| Point | cp |
| Point | p2 |
| Point | weight |
Definition at line 226 of file path_component.h.
| using impeller::ConicPathComponent::PointProc = std::function<void(const Point& point)> |
Definition at line 255 of file path_component.h.
|
inline |
Definition at line 245 of file path_component.h.
|
inline |
Definition at line 247 of file path_component.h.
| void impeller::ConicPathComponent::AppendPolylinePoints | ( | Scalar | scale_factor, |
| std::vector< Point > & | points | ||
| ) | const |
Definition at line 343 of file path_component.cc.
References ToLinearPathComponents().
Referenced by impeller::Path::CreatePolyline().
| size_t impeller::ConicPathComponent::CountLinearPathComponents | ( | Scalar | scale | ) | const |
Definition at line 362 of file path_component.cc.
References impeller::ComputeConicSubdivisions(), and scale.
Referenced by impeller::Path::CountStorage().
| std::vector< Point > impeller::ConicPathComponent::Extrema | ( | ) | const |
Definition at line 366 of file path_component.cc.
References ToQuadraticPathComponents().
| std::optional< Vector2 > impeller::ConicPathComponent::GetEndDirection | ( | ) | const |
| std::optional< Vector2 > impeller::ConicPathComponent::GetStartDirection | ( | ) | const |
|
inline |
Definition at line 327 of file path_component.cc.
References impeller::ConicSolve(), cp, p1, p2, weight, impeller::TPoint< T >::x, and impeller::TPoint< T >::y.
Referenced by impeller::testing::TEST_P(), and ToLinearPathComponents().
| void impeller::ConicPathComponent::SubdivideToQuadraticPoints | ( | std::array< Point, 5 > & | points | ) | const |
Definition at line 395 of file path_component.cc.
References cp, impeller::TPoint< T >::IsFinite(), p1, p2, scale, weight, impeller::TPoint< T >::x, and impeller::TPoint< T >::y.
Referenced by ToQuadraticPathComponents().
| void impeller::ConicPathComponent::ToLinearPathComponents | ( | Scalar | scale, |
| VertexWriter & | writer | ||
| ) | const |
Definition at line 353 of file path_component.cc.
References impeller::ComputeConicSubdivisions(), p2, scale, Solve(), and impeller::VertexWriter::Write().
| void impeller::ConicPathComponent::ToLinearPathComponents | ( | Scalar | scale_factor, |
| const PointProc & | proc | ||
| ) | const |
Definition at line 334 of file path_component.cc.
References impeller::ComputeConicSubdivisions(), p2, and Solve().
Referenced by AppendPolylinePoints(), and impeller::Path::WritePolyline().
| std::array< QuadraticPathComponent, 2 > impeller::ConicPathComponent::ToQuadraticPathComponents | ( | ) | const |
Definition at line 435 of file path_component.cc.
References SubdivideToQuadraticPoints().
Referenced by Extrema().
| Point impeller::ConicPathComponent::cp |
Definition at line 230 of file path_component.h.
Referenced by impeller::ComputeConicSubdivisions(), GetEndDirection(), GetStartDirection(), operator==(), Solve(), SubdivideToQuadraticPoints(), and impeller::testing::TEST().
| Point impeller::ConicPathComponent::p1 |
Definition at line 228 of file path_component.h.
Referenced by impeller::ComputeConicSubdivisions(), GetEndDirection(), GetStartDirection(), operator==(), impeller::PathBuilder::Shift(), Solve(), SubdivideToQuadraticPoints(), impeller::testing::TEST(), impeller::testing::TEST_P(), and impeller::Path::WritePolyline().
| Point impeller::ConicPathComponent::p2 |
Definition at line 232 of file path_component.h.
Referenced by impeller::ComputeConicSubdivisions(), GetEndDirection(), GetStartDirection(), operator==(), Solve(), SubdivideToQuadraticPoints(), impeller::testing::TEST(), impeller::testing::TEST_P(), and ToLinearPathComponents().
| Point impeller::ConicPathComponent::weight |
Definition at line 243 of file path_component.h.
Referenced by impeller::ComputeConicSubdivisions(), operator==(), Solve(), SubdivideToQuadraticPoints(), and impeller::testing::TEST().