> Either way you'll be checking thickness twice if its non-zero. The
> trivial way to avoid that would be to simply unfold the loop. Like
> points[DOWN].push_back (scm_transform (trans, curve.control_ + DOWN *
> if (th != 0.0)
> points[UP].push_back (scm_transform (trans, curve.control_ + UP *
the UP/DOWN manipulation has been a frequent source of errors in cut &
paste code, so I'd like to keep the loops.
> Written like that, it actually becomes far from trivial to see why this
> optimisation would be valid, so maybe add a comment explaining it for
> the sake of human readers?
The thickness check is cheap. The expensive bit is calculating
directions and bezier points. I added a comment.