mirror of
https://github.com/revarbat/BOSL2.git
synced 2025-08-07 11:56:30 +02:00
Fix apply() to handle degenerate input of empty list.
This commit is contained in:
@@ -407,6 +407,7 @@ function affine3d_chain(affines, _m=undef, _i=0) =
|
||||
// transformed = apply(rot(45), circle(r=3)); // Rotates 2d circle data by 45 deg
|
||||
// transformed = apply(rot(45)*right(4)*scale(3), circle(r=3)); // Scales, translates and rotates 2d circle data
|
||||
function apply(transform,points) =
|
||||
points==[] ? [] :
|
||||
is_vector(points) ? apply(transform, [points])[0] :
|
||||
let(
|
||||
tdim = len(transform[0])-1,
|
||||
|
Reference in New Issue
Block a user