1
0
mirror of https://github.com/JustinSDK/dotSCAD.git synced 2025-08-01 04:20:27 +02:00

fix off-1 error

This commit is contained in:
Justin Lin
2022-08-02 15:04:59 +08:00
parent ef07707cdb
commit 9ef35e42bd

View File

@@ -3,8 +3,8 @@ use <_impl/_tri_subdivide_impl.scad>
function tri_subdivide(shape_pts, n) =
n == 0 ? [shape_pts] :
let(
pts = _tri_subdivide_pts(shape_pts, n),
indices = _tri_subdivide_indices(n)
pts = _tri_subdivide_pts(shape_pts, n + 1),
indices = _tri_subdivide_indices(n + 1)
)
[
for(ti = indices)