HTML5 Canvas Quadratic Curve Tutorial

To create a quadratic curve with HTML5 Canvas, we can use the quadraticCurveTo() method. Quadratic curves are defined by the context point, a control point, and an ending point.  Quadratic curves can be styled with thelineWidthstrokeStyle, and lineCap properties.

A control point defines the curvature of your quadratic curve by creating two imaginary tangential lines which are connected to the context point and the ending point. The context point is defined by the moveTo() method. Moving the control point farther away from the context point and the ending point will create sharper curves, and moving the control point closer to the context point and the ending point will create broader curves.


邮箱:
密码:

微信扫描二维码捐赠

当前实例由www.100sucai.com整理,
仅作学习参考。感谢大家对本站的支持
web前端交流群:Css Js 网站美工
Bezier Curve