mirror of
https://github.com/BelfrySCAD/BOSL2.git
synced 2025-01-01 09:49:45 +00:00
Make stroke() assert that path is 2D.
This commit is contained in:
parent
e2e6bcf2f9
commit
e60648dadd
1 changed files with 1 additions and 0 deletions
|
@ -33,6 +33,7 @@ module stroke(path, width=1, endcaps=true, close=false)
|
|||
{
|
||||
$fn = quantup(segs(width/2),4);
|
||||
path = close? concat(path,[path[0]]) : path;
|
||||
assert(is_list(path) && is_vector(path[0]) && len(path[0])==2, "path must be a 2D list of points.");
|
||||
segments = pair(path);
|
||||
segpairs = pair(segments);
|
||||
|
||||
|
|
Loading…
Reference in a new issue