diff --git a/regions.scad b/regions.scad index 8dca3cfa..2c0466b7 100644 --- a/regions.scad +++ b/regions.scad @@ -1016,7 +1016,7 @@ function offset( path, r=undef, delta=undef, chamfer=false, closed=true, check_valid=true, quality=1, error=true, return_faces=false, firstface_index=0, - flip_faces=false, same_length=false + flip_faces=false, same_length=false, _reduce_output_count=false ) = assert(!(same_length && return_faces), "\nCannot combine return_faces with same_length.") is_region(path)? @@ -1097,7 +1097,7 @@ function offset( goodsegs[i][0]-goodpath[i])) assert(!outsidecorner[i] || vang!=0, // If outsidecorner[i] is true then vang>0 needed to give valid step count "\nOffset computation failed, probably because validity check mistakenly removed a valid segment. Increasing quality might fix this.") - 1+segs(r,vang) + segs(r,vang)+(_reduce_output_count ? 0 : 1) ], // newcorners is a list where each entry is a list of the points that correspond to a single point in the sharpcorners // list: newcorners[i] is the point list that replaces goodpath[i]. Without rounding or chamfering (or reversals), diff --git a/rounding.scad b/rounding.scad index 1f4ed4b3..6e6b4d02 100644 --- a/rounding.scad +++ b/rounding.scad @@ -1679,7 +1679,7 @@ function _make_offset_polyhedron(path,offsets, offset_type, flip_faces, quality, check_valid=check_valid, quality=quality, return_faces=true, firstface_index=vertexcount, - flip_faces=flip_faces + flip_faces=flip_faces, _reduce_output_count=true ) ) _make_offset_polyhedron(