cube([infty, infty, body_h+2*eps]);
}
+module left_side(w, h) {
+ for (i=[0:$children]) {
+ translate([w/2, 0, 0])
+ rotate([0, 0, 90+atan(w/(2*h))])
+ translate([infty/5, 0, 0])
+ child(i);
+ }
+}
+
module triangle(w, h) {
intersection() {
union() {
tbar();
- translate([w/2, 0, 0])
- rotate([0, 0, 90+atan(w/(2*h))])
- translate([infty/5, 0, 0])
- tbar();
- translate([-w/2, 0, 0])
- rotate([0, 0, -90-atan(w/(2*h))])
- translate([-infty/5, 0, 0])
- tbar();
+ left_side(w, h) tbar();
+ scale([-1, 1, 1]) left_side(w, h) tbar();
}
side_cube();
- translate([w/2, 0, 0])
- rotate([0, 0, 90+atan(w/(2*h))])
- translate([infty/5, 0, 0])
- side_cube();
- translate([-w/2, 0, 0])
- rotate([0, 0, -90-atan(w/(2*h))])
- translate([-infty/5, 0, 0])
- side_cube();
+ left_side(w, h) side_cube();
+ scale([-1, 1, 1]) left_side(w, h) side_cube();
}
}