1
0
mirror of https://github.com/Pomax/BezierInfo-2.git synced 2025-09-28 00:59:00 +02:00

curve from points

This commit is contained in:
Pomax
2020-08-31 23:18:43 -07:00
parent f52727160f
commit fbec463127
18 changed files with 483 additions and 194 deletions

View File

@@ -465,11 +465,18 @@ class GraphicsAPI extends BaseAPI {
}
/**
* Draw a circle around a Point
* Draw a circle
*/
circle(x, y, r) {
this.arc(x, y, r, 0, this.TAU);
}
/**
* Draw a circular arc
*/
arc(x, y, r, s, e) {
this.ctx.beginPath();
this.ctx.arc(x, y, r, 0, this.TAU);
this.ctx.arc(x, y, r, s, e);
this.ctx.fill();
this.ctx.stroke();
}