Vec2D v = this.getPos(t);
if (t != 0) {
SketchPoint nodeBetween = this.getNodeBetween(t - step, t);
if (nodeBetween != null) {
loop.add(new Vector2D(nodeBetween.x, nodeBetween.y));
}
}
if (prevVec == null || v.x != prevVec.x && v.y != prevVec.y
&& v != null) {
prevVec = v;
loop.add(new Vector2D(v.x, v.y));
}
}
} else {
for (int i = 1; i < this.l.size(); i++) {
SketchPoint v = this.l.get(i);
if (prevVec == null || v.x != prevVec.x && v.y != prevVec.y) {
prevVec = v;
loop.add(new Vector2D(v.x, v.y));
}
}
}