mirror of
https://github.com/revarbat/BOSL2.git
synced 2025-01-16 21:58:27 +01:00
Bugfixes for rot()
This commit is contained in:
parent
aa429aa1a1
commit
48478434ff
@ -284,9 +284,9 @@ function rot(a=0, v=undef, cp=undef, from=undef, to=undef, reverse=false, p=unde
|
|||||||
rot(a=a, v=v, cp=cp, from=from, to=to, reverse=reverse, p=[p], planar=planar)[0]
|
rot(a=a, v=v, cp=cp, from=from, to=to, reverse=reverse, p=[p], planar=planar)[0]
|
||||||
) : (
|
) : (
|
||||||
planar? (
|
planar? (
|
||||||
is_undef(from)? rotate_points2d(p, a=ang*rev, cp=cp) : (
|
is_undef(from)? rotate_points2d(p, a=a*rev, cp=cp) : (
|
||||||
approx(from,to)? p :
|
approx(from,to)? p :
|
||||||
rotate_points2d(p, ang=vector_angle(from,to)*sign(vector_axis(from,to)[2])*rev, cp=cp)
|
rotate_points2d(p, a=vector_angle(from,to)*sign(vector_axis(from,to)[2])*rev, cp=cp)
|
||||||
)
|
)
|
||||||
) : (
|
) : (
|
||||||
rotate_points3d(p, a=a, v=v, cp=(is_undef(cp)? [0,0,0] : cp), from=from, to=to, reverse=reverse)
|
rotate_points3d(p, a=a, v=v, cp=(is_undef(cp)? [0,0,0] : cp), from=from, to=to, reverse=reverse)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user