Smooth Bezier Segment for UWP

Agha Khan 166 Reputation points
2020-11-12T20:00:55.097+00:00

If we look WPF implementation of Bezier cure you will find 3 functions (WPF mini-language) C for cubic Bezier (3 arguments) Q for QuadraticBezierSegment (2 arguments) and S for Smooth Bezier Segment (2 arguments). So, this path works fine which contains C, Q and S
<GeometryDrawing Brush="#66423C" Geometry="M 314.7,514 C 314.7,514,287.2,549.7,243.5,564.3 S 190.8,577,186.1,587.7 C 186.1,587.7,176.2,594.6,156.3,596.5 C 136.4,598.4,140,598.4,136.2,609.8 C 136.2,609.8,107.9,622,96.8,648.1 C 85.7,674.2,70.2,673.8,76.9,701.4 C 76.9,701.4,64,745.1,62.5,784.8 C 62.5,784.8,42.3,791.2,54.3,821.5 C 54.3,821.5,41.6,852.6,37.7,871.7 L 782.5,871.7 C 779.9,860.1,764.8,792.1,759.6,759.2 C 754,723.2,743.5,668.1,732.6,623.4 C 721.7,578.8,721.5,585.7,702.2,570.9 S 654.2,539.4,614.6,533.2 C 575,527,549,517.6,511.8,497.8 C 474.7,477.9,463.1,505.7,463.1,505.7 L 314.7,514 L 314.7,514z " />
In UWP we have
<BezierSegment Point1=\"{temCtrl1.X},{temCtrl1.Y}\" Point2=\"{temEnd.X},{temEnd.Y}\" />"
And
"<QuadraticBezierSegment Point1=\"{temCtrl1.X},{temCtrl1.Y}\" Point2=\"{temEnd.X},{temEnd.Y}\" />
But what is the syntax foe Smooth Bezier Segment?

Universal Windows Platform (UWP)
Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,770 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Agha Khan 166 Reputation points
    2020-11-13T19:26:18.207+00:00

    The easy way to achieve this behavior to save previous control point. Now we have three arguments and it works fine.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.