mirror of
https://github.com/revarbat/BOSL2.git
synced 2025-08-31 12:31:51 +02:00
fix various stroke() bugs, add attachable() to some modules
This commit is contained in:
@@ -359,14 +359,18 @@ module extrude_from_to(pt1, pt2, convexity, twist, scale, slices) {
|
||||
pt1 = point3d(pt1);
|
||||
pt2 = point3d(pt2);
|
||||
rtp = xyz_to_spherical(pt2-pt1);
|
||||
translate(pt1) {
|
||||
rotate([0, rtp[2], rtp[1]]) {
|
||||
if (rtp[0] > 0) {
|
||||
linear_extrude(height=rtp[0], convexity=convexity, center=false, slices=slices, twist=twist, scale=scale) {
|
||||
children();
|
||||
}
|
||||
}
|
||||
}
|
||||
attachable()
|
||||
{
|
||||
translate(pt1) {
|
||||
rotate([0, rtp[2], rtp[1]]) {
|
||||
if (rtp[0] > 0) {
|
||||
linear_extrude(height=rtp[0], convexity=convexity, center=false, slices=slices, twist=twist, scale=scale) {
|
||||
children();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
union();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user