Class CubicBezierLineSegment
Represents a line segment that contains a lists of control points that will be rendered as a cubic bezier curve
Implements
Inherited Members
Namespace: SixLabors.ImageSharp.Drawing
Assembly: SixLabors.ImageSharp.Drawing.dll
Syntax
public sealed class CubicBezierLineSegment : ILineSegment
Constructors
| Improve this Doc View SourceCubicBezierLineSegment(PointF, PointF, PointF, PointF, PointF[])
Initializes a new instance of the CubicBezierLineSegment class.
Declaration
public CubicBezierLineSegment(PointF start, PointF controlPoint1, PointF controlPoint2, PointF end, params PointF[] additionalPoints)
Parameters
Type | Name | Description |
---|---|---|
PointF | start | The start. |
PointF | controlPoint1 | The control point1. |
PointF | controlPoint2 | The control point2. |
PointF | end | The end. |
PointF[] | additionalPoints | The additional points. |
CubicBezierLineSegment(PointF[])
Initializes a new instance of the CubicBezierLineSegment class.
Declaration
public CubicBezierLineSegment(PointF[] points)
Parameters
Type | Name | Description |
---|---|---|
PointF[] | points | The points. |
Properties
| Improve this Doc View SourceControlPoints
Gets the control points.
Declaration
public IReadOnlyList<PointF> ControlPoints { get; }
Property Value
Type | Description |
---|---|
IReadOnlyList<PointF> | The control points. |
EndPoint
Gets the end point.
Declaration
public PointF EndPoint { get; }
Property Value
Type | Description |
---|---|
PointF | The end point. |
Methods
| Improve this Doc View SourceFlatten()
Returns the current ILineSegment a simple linear path.
Declaration
public ReadOnlyMemory<PointF> Flatten()
Returns
Type | Description |
---|---|
ReadOnlyMemory<PointF> | Returns the current ILineSegment as simple linear path. |
Transform(Matrix3x2)
Transforms the current LineSegment using specified matrix.
Declaration
public CubicBezierLineSegment Transform(Matrix3x2 matrix)
Parameters
Type | Name | Description |
---|---|---|
Matrix3x2 | matrix | The matrix. |
Returns
Type | Description |
---|---|
CubicBezierLineSegment | A line segment with the matrix applied to it. |
Explicit Interface Implementations
| Improve this Doc View SourceILineSegment.Transform(Matrix3x2)
Transforms the current LineSegment using specified matrix.
Declaration
ILineSegment ILineSegment.Transform(Matrix3x2 matrix)
Parameters
Type | Name | Description |
---|---|---|
Matrix3x2 | matrix | The matrix. |
Returns
Type | Description |
---|---|
ILineSegment | A line segment with the matrix applied to it. |