summaryrefslogtreecommitdiff
path: root/examples/example006.scad
diff options
context:
space:
mode:
Diffstat (limited to 'examples/example006.scad')
-rw-r--r--examples/example006.scad28
1 files changed, 14 insertions, 14 deletions
diff --git a/examples/example006.scad b/examples/example006.scad
index 26143a1..548339d 100644
--- a/examples/example006.scad
+++ b/examples/example006.scad
@@ -4,12 +4,12 @@ module example006()
module edgeprofile()
{
render(convexity = 2) difference() {
- cube([20 20 150], center = true);
- translate([-10 -10 0])
+ cube([20, 20, 150], center = true);
+ translate([-10, -10, 0])
cylinder(h = 80, r = 10, center = true);
- translate([-10 -10 +40])
+ translate([-10, -10, +40])
sphere(r = 10);
- translate([-10 -10 -40])
+ translate([-10, -10, -40])
sphere(r = 10);
}
}
@@ -17,23 +17,23 @@ module example006()
difference()
{
cube(100, center = true);
- for (rot = [ [0 0 0], [1 0 0], [0 1 0] ]) {
+ for (rot = [ [0, 0, 0], [1, 0, 0], [0, 1, 0] ]) {
rotate(90, rot)
- for (p = [[+1 +1 0], [-1 +1 90], [-1 -1 180], [+1 -1 270]]) {
+ for (p = [[+1, +1, 0], [-1, +1, 90], [-1, -1, 180], [+1, -1, 270]]) {
translate([ p[0]*50, p[1]*50, 0 ])
- rotate(p[2], [0 0 1])
+ rotate(p[2], [0, 0, 1])
edgeprofile();
}
}
for (i = [
- [ 0, 0, [ [0 0] ] ],
- [ 90, 0, [ [-20 -20], [+20 +20] ] ],
- [ 180, 0, [ [-20 -25], [-20 0], [-20 +25], [+20 -25], [+20 0], [+20 +25] ] ],
- [ 270, 0, [ [0 0], [-25 -25], [+25 -25], [-25 +25], [+25 +25] ] ],
- [ 0, 90, [ [-25 -25], [0 0], [+25 +25] ] ],
- [ 0, -90, [ [-25 -25], [+25 -25], [-25 +25], [+25 +25] ] ]
+ [ 0, 0, [ [0, 0] ] ],
+ [ 90, 0, [ [-20, -20], [+20, +20] ] ],
+ [ 180, 0, [ [-20, -25], [-20, 0], [-20, +25], [+20, -25], [+20, 0], [+20, +25] ] ],
+ [ 270, 0, [ [0, 0], [-25, -25], [+25, -25], [-25, +25], [+25, +25] ] ],
+ [ 0, 90, [ [-25, -25], [0, 0], [+25, +25] ] ],
+ [ 0, -90, [ [-25, -25], [+25, -25], [-25, +25], [+25, +25] ] ]
]) {
- rotate(i[0], [0 0 1]) rotate(i[1], [1 0 0]) translate([0 -50 0])
+ rotate(i[0], [0, 0, 1]) rotate(i[1], [1, 0, 0]) translate([0, -50, 0])
for (j = i[2])
translate([j[0], 0, j[1]]) sphere(10);
}
contact: Jan Huwald // Impressum