mirror of
https://github.com/Pomax/BezierInfo-2.git
synced 2025-08-30 03:30:34 +02:00
image regeneration
This commit is contained in:
@@ -19,7 +19,7 @@ draw() {
|
||||
|
||||
var reduced = this.reduce(curve);
|
||||
reduced.forEach(c => {
|
||||
setStroke( randomColor() );
|
||||
setStroke(randomColor() );
|
||||
this.drawCurve(c);
|
||||
circle(c.points[0].x, c.points[0].y, 2);
|
||||
});
|
||||
@@ -93,7 +93,7 @@ reduce(curve) {
|
||||
segment = p1.split(t1, t2);
|
||||
if (!segment.simple()) {
|
||||
t2 -= step;
|
||||
if ( abs(t1 - t2) < step) {
|
||||
if (abs(t1 - t2) < step) {
|
||||
// we can never form a reduction
|
||||
return [];
|
||||
}
|
||||
|
Reference in New Issue
Block a user