mirror of
https://github.com/Pomax/BezierInfo-2.git
synced 2025-08-29 19:20:39 +02:00
figured out how to reuse sketches with data-attribute parameters
This commit is contained in:
@@ -1,12 +1,13 @@
|
||||
let curve;
|
||||
|
||||
setup() {
|
||||
const curve = this.curve = new Bezier(this, 70,250, 120,15, 20,95, 225,80);
|
||||
curve = new Bezier(this, 70,250, 120,15, 20,95, 225,80);
|
||||
setMovable(curve.points);
|
||||
}
|
||||
|
||||
draw() {
|
||||
clear();
|
||||
|
||||
const curve = this.curve;
|
||||
curve.drawSkeleton();
|
||||
curve.drawCurve();
|
||||
curve.drawPoints();
|
||||
|
Reference in New Issue
Block a user