From 400248d566d5c3db34253a94f70c128e68ea9121 Mon Sep 17 00:00:00 2001 From: chrysn Date: Mon, 24 Jun 2013 17:20:33 +0200 Subject: renamed dumptest files to .csg and added group headers diff --git a/tests/regression/dumptest/2d-3d-expected.csg b/tests/regression/dumptest/2d-3d-expected.csg new file mode 100644 index 0000000..a2f6422 --- /dev/null +++ b/tests/regression/dumptest/2d-3d-expected.csg @@ -0,0 +1,6 @@ +group() { + cube(size = [1, 1, 1], center = false); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } +} diff --git a/tests/regression/dumptest/2d-3d-expected.txt b/tests/regression/dumptest/2d-3d-expected.txt deleted file mode 100644 index 5789ed7..0000000 --- a/tests/regression/dumptest/2d-3d-expected.txt +++ /dev/null @@ -1,5 +0,0 @@ - cube(size = [1, 1, 1], center = false); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - diff --git a/tests/regression/dumptest/allexpressions-expected.csg b/tests/regression/dumptest/allexpressions-expected.csg new file mode 100644 index 0000000..6009957 --- /dev/null +++ b/tests/regression/dumptest/allexpressions-expected.csg @@ -0,0 +1,2 @@ +group() { +} diff --git a/tests/regression/dumptest/allexpressions-expected.txt b/tests/regression/dumptest/allexpressions-expected.txt deleted file mode 100644 index 8b13789..0000000 --- a/tests/regression/dumptest/allexpressions-expected.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/tests/regression/dumptest/allfunctions-expected.csg b/tests/regression/dumptest/allfunctions-expected.csg new file mode 100644 index 0000000..6009957 --- /dev/null +++ b/tests/regression/dumptest/allfunctions-expected.csg @@ -0,0 +1,2 @@ +group() { +} diff --git a/tests/regression/dumptest/allfunctions-expected.txt b/tests/regression/dumptest/allfunctions-expected.txt deleted file mode 100644 index 8b13789..0000000 --- a/tests/regression/dumptest/allfunctions-expected.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/tests/regression/dumptest/allmodules-expected.csg b/tests/regression/dumptest/allmodules-expected.csg new file mode 100644 index 0000000..42bf4fa --- /dev/null +++ b/tests/regression/dumptest/allmodules-expected.csg @@ -0,0 +1,42 @@ +group() { + minkowski(convexity = 0); + glide(path = undef, convexity = 0); + subdiv(level = 1, convexity = 0); + hull(); + resize(newsize = [0,0,0], auto = [0,0,0]); + group(); + group(); + group(); + intersection(); + group() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 1); + } + union(); + difference(); + intersection(); + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + group(); + cube(size = [1, 1, 1], center = false); + sphere($fn = 0, $fa = 12, $fs = 2, r = 1); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); + polyhedron(points = undef, triangles = undef, convexity = 1); + square(size = [1, 1], center = false); + circle($fn = 0, $fa = 12, $fs = 2, r = 1); + polygon(points = undef, paths = undef, convexity = 1); + projection(cut = false, convexity = 0); + render(convexity = 1); + surface(file = "", center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[-1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + color([-1, -1, -1, 1]); +} diff --git a/tests/regression/dumptest/allmodules-expected.txt b/tests/regression/dumptest/allmodules-expected.txt deleted file mode 100644 index 74bf191..0000000 --- a/tests/regression/dumptest/allmodules-expected.txt +++ /dev/null @@ -1,41 +0,0 @@ - minkowski(convexity = 0); - glide(path = undef, convexity = 0); - subdiv(level = 1, convexity = 0); - hull(); - resize(newsize = [0,0,0], auto = [0,0,0]); - group(); - group(); - group(); - intersection(); - group() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 1); - } - union(); - difference(); - intersection(); - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - group(); - cube(size = [1, 1, 1], center = false); - sphere($fn = 0, $fa = 12, $fs = 2, r = 1); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - polyhedron(points = undef, triangles = undef, convexity = 1); - square(size = [1, 1], center = false); - circle($fn = 0, $fa = 12, $fs = 2, r = 1); - polygon(points = undef, paths = undef, convexity = 1); - projection(cut = false, convexity = 0); - render(convexity = 1); - surface(file = "", center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[-1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - color([-1, -1, -1, 1]); - diff --git a/tests/regression/dumptest/assign-expected.csg b/tests/regression/dumptest/assign-expected.csg new file mode 100644 index 0000000..434cc8f --- /dev/null +++ b/tests/regression/dumptest/assign-expected.csg @@ -0,0 +1,3 @@ +group() { + group(); +} diff --git a/tests/regression/dumptest/assign-expected.txt b/tests/regression/dumptest/assign-expected.txt deleted file mode 100644 index b2915cb..0000000 --- a/tests/regression/dumptest/assign-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - group(); - diff --git a/tests/regression/dumptest/assign-tests-expected.csg b/tests/regression/dumptest/assign-tests-expected.csg new file mode 100644 index 0000000..df147fe --- /dev/null +++ b/tests/regression/dumptest/assign-tests-expected.csg @@ -0,0 +1,52 @@ +group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [0, 0, 0], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [0, 0, 0], center = false); + } + } + } + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [0.5, 0.5, 0.5], center = false); + } + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [2, 2, 2], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [1, 1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 4.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [3, 3, 3], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [1.5, 1.5, 1.5], center = false); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [4, 4, 4], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = false); + } + } + } + multmatrix([[1, 0, 0, 12.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [5, 5, 5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2.5, 2.5, 2.5], center = false); + } + } + } + } +} diff --git a/tests/regression/dumptest/assign-tests-expected.txt b/tests/regression/dumptest/assign-tests-expected.txt deleted file mode 100644 index f9db497..0000000 --- a/tests/regression/dumptest/assign-tests-expected.txt +++ /dev/null @@ -1,51 +0,0 @@ - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [0, 0, 0], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [0, 0, 0], center = false); - } - } - } - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [0.5, 0.5, 0.5], center = false); - } - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [2, 2, 2], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [1, 1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 4.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [3, 3, 3], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [1.5, 1.5, 1.5], center = false); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [4, 4, 4], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = false); - } - } - } - multmatrix([[1, 0, 0, 12.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [5, 5, 5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2.5, 2.5, 2.5], center = false); - } - } - } - } - diff --git a/tests/regression/dumptest/background-modifier-expected.csg b/tests/regression/dumptest/background-modifier-expected.csg new file mode 100644 index 0000000..4d6d019 --- /dev/null +++ b/tests/regression/dumptest/background-modifier-expected.csg @@ -0,0 +1,21 @@ +group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + %cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + } + %group() { + cube(size = [25, 6, 3], center = true); + } + %multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + color([0, 0.501961, 0, 1]) { + cube(size = [10, 4, 10], center = true); + } + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + } +} diff --git a/tests/regression/dumptest/background-modifier-expected.txt b/tests/regression/dumptest/background-modifier-expected.txt deleted file mode 100644 index 5861bef..0000000 --- a/tests/regression/dumptest/background-modifier-expected.txt +++ /dev/null @@ -1,20 +0,0 @@ - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - %cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - } - %group() { - cube(size = [25, 6, 3], center = true); - } - %multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - color([0, 0.501961, 0, 1]) { - cube(size = [10, 4, 10], center = true); - } - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - } - diff --git a/tests/regression/dumptest/child-background-expected.csg b/tests/regression/dumptest/child-background-expected.csg new file mode 100644 index 0000000..fa0286c --- /dev/null +++ b/tests/regression/dumptest/child-background-expected.csg @@ -0,0 +1,8 @@ +group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + } + } +} diff --git a/tests/regression/dumptest/child-background-expected.txt b/tests/regression/dumptest/child-background-expected.txt deleted file mode 100644 index c3e8288..0000000 --- a/tests/regression/dumptest/child-background-expected.txt +++ /dev/null @@ -1,7 +0,0 @@ - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - } - } - diff --git a/tests/regression/dumptest/child-child-test-expected.csg b/tests/regression/dumptest/child-child-test-expected.csg new file mode 100644 index 0000000..2480558 --- /dev/null +++ b/tests/regression/dumptest/child-child-test-expected.csg @@ -0,0 +1,60 @@ +group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + } + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + color([1, 0, 0, 1]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + color([1, 0, 0, 1]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + } + } + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/child-child-test-expected.txt b/tests/regression/dumptest/child-child-test-expected.txt deleted file mode 100644 index 13f098d..0000000 --- a/tests/regression/dumptest/child-child-test-expected.txt +++ /dev/null @@ -1,59 +0,0 @@ - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - } - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - color([1, 0, 0, 1]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - color([1, 0, 0, 1]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - } - } - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/child-expected.csg b/tests/regression/dumptest/child-expected.csg new file mode 100644 index 0000000..6009957 --- /dev/null +++ b/tests/regression/dumptest/child-expected.csg @@ -0,0 +1,2 @@ +group() { +} diff --git a/tests/regression/dumptest/child-expected.txt b/tests/regression/dumptest/child-expected.txt deleted file mode 100644 index 8b13789..0000000 --- a/tests/regression/dumptest/child-expected.txt +++ /dev/null @@ -1 +0,0 @@ - diff --git a/tests/regression/dumptest/child-tests-expected.csg b/tests/regression/dumptest/child-tests-expected.csg new file mode 100644 index 0000000..62363ff --- /dev/null +++ b/tests/regression/dumptest/child-tests-expected.csg @@ -0,0 +1,53 @@ +group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 16, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 16, $fa = 12, $fs = 2, h = 2, r1 = 1, r2 = 1, center = true); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [2, 2, 2], center = true); + } + } + } + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 16, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + } + } + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 16, $fa = 12, $fs = 2, h = 2, r1 = 1, r2 = 1, center = true); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group(); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 16, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = true); + } + } + } + } +} diff --git a/tests/regression/dumptest/child-tests-expected.txt b/tests/regression/dumptest/child-tests-expected.txt deleted file mode 100644 index e1a7557..0000000 --- a/tests/regression/dumptest/child-tests-expected.txt +++ /dev/null @@ -1,52 +0,0 @@ - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 16, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 16, $fa = 12, $fs = 2, h = 2, r1 = 1, r2 = 1, center = true); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [2, 2, 2], center = true); - } - } - } - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 16, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - } - } - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 16, $fa = 12, $fs = 2, h = 2, r1 = 1, r2 = 1, center = true); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group(); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 16, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = true); - } - } - } - } - diff --git a/tests/regression/dumptest/circle-expected.csg b/tests/regression/dumptest/circle-expected.csg new file mode 100644 index 0000000..19c862b --- /dev/null +++ b/tests/regression/dumptest/circle-expected.csg @@ -0,0 +1,3 @@ +group() { + circle($fn = 0, $fa = 12, $fs = 2, r = 1); +} diff --git a/tests/regression/dumptest/circle-expected.txt b/tests/regression/dumptest/circle-expected.txt deleted file mode 100644 index 1e7bd9a..0000000 --- a/tests/regression/dumptest/circle-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - circle($fn = 0, $fa = 12, $fs = 2, r = 1); - diff --git a/tests/regression/dumptest/circle-tests-expected.csg b/tests/regression/dumptest/circle-tests-expected.csg new file mode 100644 index 0000000..b522850 --- /dev/null +++ b/tests/regression/dumptest/circle-tests-expected.csg @@ -0,0 +1,33 @@ +group() { + circle($fn = 0, $fa = 12, $fs = 2, r = 1); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 0); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 4, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, -3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, -3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 12, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 20, $fs = 0.3, r = 1); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 30, $fs = 0.3, r = 1); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 40, $fs = 0.3, r = 1); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0.1, $fa = 12, $fs = 2, r = 1); + } +} diff --git a/tests/regression/dumptest/circle-tests-expected.txt b/tests/regression/dumptest/circle-tests-expected.txt deleted file mode 100644 index 28359d8..0000000 --- a/tests/regression/dumptest/circle-tests-expected.txt +++ /dev/null @@ -1,32 +0,0 @@ - circle($fn = 0, $fa = 12, $fs = 2, r = 1); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 0); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 4, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, -3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, -3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 12, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 20, $fs = 0.3, r = 1); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 30, $fs = 0.3, r = 1); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 40, $fs = 0.3, r = 1); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0.1, $fa = 12, $fs = 2, r = 1); - } - diff --git a/tests/regression/dumptest/color-expected.csg b/tests/regression/dumptest/color-expected.csg new file mode 100644 index 0000000..ef862fc --- /dev/null +++ b/tests/regression/dumptest/color-expected.csg @@ -0,0 +1,3 @@ +group() { + color([-1, -1, -1, 1]); +} diff --git a/tests/regression/dumptest/color-expected.txt b/tests/regression/dumptest/color-expected.txt deleted file mode 100644 index cead62d..0000000 --- a/tests/regression/dumptest/color-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - color([-1, -1, -1, 1]); - diff --git a/tests/regression/dumptest/color-tests-expected.csg b/tests/regression/dumptest/color-tests-expected.csg new file mode 100644 index 0000000..a65fdc6 --- /dev/null +++ b/tests/regression/dumptest/color-tests-expected.csg @@ -0,0 +1,65 @@ +group() { + color([-1, -1, -1, 1]); + color([-1, -1, -1, 1]); + multmatrix([[1, 0, 0, 12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 24], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.501961, 0, 0.501961, 1]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + color([0, 0, 1, 0.5]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0, 1, 0.5]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.501961, 0, 0.2]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, -12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([-1, -1, -1, 1]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([-1, -1, -1, 0.5]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, 24], [0, 1, 0, -12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0, 0, 1]) { + color([0, 0, 1, 1]) { + group() { + cube(size = [10, 10, 10], center = false); + } + } + } + } +} diff --git a/tests/regression/dumptest/color-tests-expected.txt b/tests/regression/dumptest/color-tests-expected.txt deleted file mode 100644 index 95fe012..0000000 --- a/tests/regression/dumptest/color-tests-expected.txt +++ /dev/null @@ -1,64 +0,0 @@ - color([-1, -1, -1, 1]); - color([-1, -1, -1, 1]); - multmatrix([[1, 0, 0, 12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 24], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.501961, 0, 0.501961, 1]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - color([0, 0, 1, 0.5]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0, 1, 0.5]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.501961, 0, 0.2]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, -12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([-1, -1, -1, 1]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([-1, -1, -1, 0.5]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, 24], [0, 1, 0, -12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0, 0, 1]) { - color([0, 0, 1, 1]) { - group() { - cube(size = [10, 10, 10], center = false); - } - } - } - } - diff --git a/tests/regression/dumptest/control-hull-dimension-expected.csg b/tests/regression/dumptest/control-hull-dimension-expected.csg new file mode 100644 index 0000000..720ebe7 --- /dev/null +++ b/tests/regression/dumptest/control-hull-dimension-expected.csg @@ -0,0 +1,6 @@ +group() { + hull() { + circle($fn = 0, $fa = 12, $fs = 2, r = 1); + group(); + } +} diff --git a/tests/regression/dumptest/control-hull-dimension-expected.txt b/tests/regression/dumptest/control-hull-dimension-expected.txt deleted file mode 100644 index be2e4ee..0000000 --- a/tests/regression/dumptest/control-hull-dimension-expected.txt +++ /dev/null @@ -1,5 +0,0 @@ - hull() { - circle($fn = 0, $fa = 12, $fs = 2, r = 1); - group(); - } - diff --git a/tests/regression/dumptest/cube-expected.csg b/tests/regression/dumptest/cube-expected.csg new file mode 100644 index 0000000..91dc5fc --- /dev/null +++ b/tests/regression/dumptest/cube-expected.csg @@ -0,0 +1,3 @@ +group() { + cube(size = [1, 1, 1], center = false); +} diff --git a/tests/regression/dumptest/cube-expected.txt b/tests/regression/dumptest/cube-expected.txt deleted file mode 100644 index d1c5d32..0000000 --- a/tests/regression/dumptest/cube-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - cube(size = [1, 1, 1], center = false); - diff --git a/tests/regression/dumptest/cube-tests-expected.csg b/tests/regression/dumptest/cube-tests-expected.csg new file mode 100644 index 0000000..848bd27 --- /dev/null +++ b/tests/regression/dumptest/cube-tests-expected.csg @@ -0,0 +1,13 @@ +group() { + cube(size = [1, 1, 1], center = false); + cube(size = [1, 1, 0], center = false); + cube(size = [1, 0, 1], center = false); + cube(size = [0, 1, 1], center = false); + cube(size = [0, 0, 0], center = false); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [2, 3, 1], center = false); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [2, 4, 2], center = true); + } +} diff --git a/tests/regression/dumptest/cube-tests-expected.txt b/tests/regression/dumptest/cube-tests-expected.txt deleted file mode 100644 index 697c433..0000000 --- a/tests/regression/dumptest/cube-tests-expected.txt +++ /dev/null @@ -1,12 +0,0 @@ - cube(size = [1, 1, 1], center = false); - cube(size = [1, 1, 0], center = false); - cube(size = [1, 0, 1], center = false); - cube(size = [0, 1, 1], center = false); - cube(size = [0, 0, 0], center = false); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [2, 3, 1], center = false); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [2, 4, 2], center = true); - } - diff --git a/tests/regression/dumptest/cylinder-expected.csg b/tests/regression/dumptest/cylinder-expected.csg new file mode 100644 index 0000000..aa99b6c --- /dev/null +++ b/tests/regression/dumptest/cylinder-expected.csg @@ -0,0 +1,3 @@ +group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); +} diff --git a/tests/regression/dumptest/cylinder-expected.txt b/tests/regression/dumptest/cylinder-expected.txt deleted file mode 100644 index 73dcb7c..0000000 --- a/tests/regression/dumptest/cylinder-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - diff --git a/tests/regression/dumptest/cylinder-tests-expected.csg b/tests/regression/dumptest/cylinder-tests-expected.csg new file mode 100644 index 0000000..5c57bca --- /dev/null +++ b/tests/regression/dumptest/cylinder-tests-expected.csg @@ -0,0 +1,39 @@ +group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0, r2 = 0, center = false); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0, r2 = 0, center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 1, center = false); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 0, center = false); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 8, r1 = 5, r2 = 5, center = false); + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 0, r2 = 5, center = true); + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 0, center = false); + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 15, r1 = 5, r2 = 5, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 6, $fa = 12, $fs = 2, h = 2, r1 = 3, r2 = 3, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0.1, $fa = 12, $fs = 2, h = 7.0711, r1 = 3.5356, r2 = 3.5356, center = true); + } +} diff --git a/tests/regression/dumptest/cylinder-tests-expected.txt b/tests/regression/dumptest/cylinder-tests-expected.txt deleted file mode 100644 index c47ffe1..0000000 --- a/tests/regression/dumptest/cylinder-tests-expected.txt +++ /dev/null @@ -1,38 +0,0 @@ - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0, r2 = 0, center = false); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0, r2 = 0, center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 1, center = false); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 0, center = false); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 8, r1 = 5, r2 = 5, center = false); - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 0, r2 = 5, center = true); - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 0, center = false); - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 15, r1 = 5, r2 = 5, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 6, $fa = 12, $fs = 2, h = 2, r1 = 3, r2 = 3, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0.1, $fa = 12, $fs = 2, h = 7.0711, r1 = 3.5356, r2 = 3.5356, center = true); - } - diff --git a/tests/regression/dumptest/difference-expected.csg b/tests/regression/dumptest/difference-expected.csg new file mode 100644 index 0000000..09b977f --- /dev/null +++ b/tests/regression/dumptest/difference-expected.csg @@ -0,0 +1,3 @@ +group() { + difference(); +} diff --git a/tests/regression/dumptest/difference-expected.txt b/tests/regression/dumptest/difference-expected.txt deleted file mode 100644 index 84a3635..0000000 --- a/tests/regression/dumptest/difference-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - difference(); - diff --git a/tests/regression/dumptest/difference-tests-expected.csg b/tests/regression/dumptest/difference-tests-expected.csg new file mode 100644 index 0000000..f2c1419 --- /dev/null +++ b/tests/regression/dumptest/difference-tests-expected.csg @@ -0,0 +1,39 @@ +group() { + difference(); + difference(); + difference() { + cube(size = [10, 10, 10], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 4, r2 = 4, center = true); + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cube(size = [10, 10, 10], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10.5, r1 = 4, r2 = 4, center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cube(size = [10, 10, 10], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 11, r1 = 4, r2 = 4, center = true); + multmatrix([[2.22045e-16, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 2.22045e-16, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 11, r1 = 4, r2 = 4, center = true); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cube(size = [10, 10, 10], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.01], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); + } + } + } + multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cube(size = [10, 10, 10], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 6.99], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); + } + } + } +} diff --git a/tests/regression/dumptest/difference-tests-expected.txt b/tests/regression/dumptest/difference-tests-expected.txt deleted file mode 100644 index 30dd001..0000000 --- a/tests/regression/dumptest/difference-tests-expected.txt +++ /dev/null @@ -1,38 +0,0 @@ - difference(); - difference(); - difference() { - cube(size = [10, 10, 10], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 4, r2 = 4, center = true); - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cube(size = [10, 10, 10], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10.5, r1 = 4, r2 = 4, center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cube(size = [10, 10, 10], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 11, r1 = 4, r2 = 4, center = true); - multmatrix([[2.22045e-16, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 2.22045e-16, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 11, r1 = 4, r2 = 4, center = true); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cube(size = [10, 10, 10], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.01], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); - } - } - } - multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cube(size = [10, 10, 10], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 6.99], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); - } - } - } - diff --git a/tests/regression/dumptest/disable-modifier-expected.csg b/tests/regression/dumptest/disable-modifier-expected.csg new file mode 100644 index 0000000..652021e --- /dev/null +++ b/tests/regression/dumptest/disable-modifier-expected.csg @@ -0,0 +1,5 @@ +group() { + difference() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + } +} diff --git a/tests/regression/dumptest/disable-modifier-expected.txt b/tests/regression/dumptest/disable-modifier-expected.txt deleted file mode 100644 index a237a48..0000000 --- a/tests/regression/dumptest/disable-modifier-expected.txt +++ /dev/null @@ -1,4 +0,0 @@ - difference() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - } - diff --git a/tests/regression/dumptest/dxf_linear_extrude-expected.csg b/tests/regression/dumptest/dxf_linear_extrude-expected.csg new file mode 100644 index 0000000..5404abf --- /dev/null +++ b/tests/regression/dumptest/dxf_linear_extrude-expected.csg @@ -0,0 +1,3 @@ +group() { + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/dxf_linear_extrude-expected.txt b/tests/regression/dumptest/dxf_linear_extrude-expected.txt deleted file mode 100644 index 9ad9e00..0000000 --- a/tests/regression/dumptest/dxf_linear_extrude-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/dxf_rotate_extrude-expected.csg b/tests/regression/dumptest/dxf_rotate_extrude-expected.csg new file mode 100644 index 0000000..54f06b3 --- /dev/null +++ b/tests/regression/dumptest/dxf_rotate_extrude-expected.csg @@ -0,0 +1,3 @@ +group() { + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/dxf_rotate_extrude-expected.txt b/tests/regression/dumptest/dxf_rotate_extrude-expected.txt deleted file mode 100644 index c212d76..0000000 --- a/tests/regression/dumptest/dxf_rotate_extrude-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/echo-expected.csg b/tests/regression/dumptest/echo-expected.csg new file mode 100644 index 0000000..434cc8f --- /dev/null +++ b/tests/regression/dumptest/echo-expected.csg @@ -0,0 +1,3 @@ +group() { + group(); +} diff --git a/tests/regression/dumptest/echo-expected.txt b/tests/regression/dumptest/echo-expected.txt deleted file mode 100644 index b2915cb..0000000 --- a/tests/regression/dumptest/echo-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - group(); - diff --git a/tests/regression/dumptest/escape-test-expected.csg b/tests/regression/dumptest/escape-test-expected.csg new file mode 100644 index 0000000..7303df8 --- /dev/null +++ b/tests/regression/dumptest/escape-test-expected.csg @@ -0,0 +1,3 @@ +group() { + import(file = "B-\" C-\t D-\n E-'", layer = "A:\\ B:\" C:\t D:\n E:' F:\\\\", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/escape-test-expected.txt b/tests/regression/dumptest/escape-test-expected.txt deleted file mode 100644 index af7f3e7..0000000 --- a/tests/regression/dumptest/escape-test-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - import(file = "B-\" C-\t D-\n E-'", layer = "A:\\ B:\" C:\t D:\n E:' F:\\\\", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/example001-expected.csg b/tests/regression/dumptest/example001-expected.csg new file mode 100644 index 0000000..ab7e4e9 --- /dev/null +++ b/tests/regression/dumptest/example001-expected.csg @@ -0,0 +1,22 @@ +group() { + group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 1, r = 25); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); + } + } + group() { + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); + } + } + } + } +} diff --git a/tests/regression/dumptest/example001-expected.txt b/tests/regression/dumptest/example001-expected.txt deleted file mode 100644 index 7d92377..0000000 --- a/tests/regression/dumptest/example001-expected.txt +++ /dev/null @@ -1,21 +0,0 @@ - group() { - difference() { - sphere($fn = 0, $fa = 12, $fs = 1, r = 25); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); - } - } - group() { - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 62.5, r1 = 12.5, r2 = 12.5, center = true); - } - } - } - } - diff --git a/tests/regression/dumptest/example002-expected.csg b/tests/regression/dumptest/example002-expected.csg new file mode 100644 index 0000000..a34dd2a --- /dev/null +++ b/tests/regression/dumptest/example002-expected.csg @@ -0,0 +1,22 @@ +group() { + group() { + intersection() { + difference() { + union() { + cube(size = [30, 30, 30], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + cube(size = [15, 15, 50], center = true); + } + } + union() { + cube(size = [50, 10, 10], center = true); + cube(size = [10, 50, 10], center = true); + cube(size = [10, 10, 50], center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 5], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 20, r2 = 5, center = true); + } + } + } +} diff --git a/tests/regression/dumptest/example002-expected.txt b/tests/regression/dumptest/example002-expected.txt deleted file mode 100644 index b3a79ce..0000000 --- a/tests/regression/dumptest/example002-expected.txt +++ /dev/null @@ -1,21 +0,0 @@ - group() { - intersection() { - difference() { - union() { - cube(size = [30, 30, 30], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - cube(size = [15, 15, 50], center = true); - } - } - union() { - cube(size = [50, 10, 10], center = true); - cube(size = [10, 50, 10], center = true); - cube(size = [10, 10, 50], center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 5], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 20, r2 = 5, center = true); - } - } - } - diff --git a/tests/regression/dumptest/example003-expected.csg b/tests/regression/dumptest/example003-expected.csg new file mode 100644 index 0000000..4afbc17 --- /dev/null +++ b/tests/regression/dumptest/example003-expected.csg @@ -0,0 +1,17 @@ +group() { + group() { + difference() { + union() { + cube(size = [30, 30, 30], center = true); + cube(size = [40, 15, 15], center = true); + cube(size = [15, 40, 15], center = true); + cube(size = [15, 15, 40], center = true); + } + union() { + cube(size = [50, 10, 10], center = true); + cube(size = [10, 50, 10], center = true); + cube(size = [10, 10, 50], center = true); + } + } + } +} diff --git a/tests/regression/dumptest/example003-expected.txt b/tests/regression/dumptest/example003-expected.txt deleted file mode 100644 index 480b032..0000000 --- a/tests/regression/dumptest/example003-expected.txt +++ /dev/null @@ -1,16 +0,0 @@ - group() { - difference() { - union() { - cube(size = [30, 30, 30], center = true); - cube(size = [40, 15, 15], center = true); - cube(size = [15, 40, 15], center = true); - cube(size = [15, 15, 40], center = true); - } - union() { - cube(size = [50, 10, 10], center = true); - cube(size = [10, 50, 10], center = true); - cube(size = [10, 10, 50], center = true); - } - } - } - diff --git a/tests/regression/dumptest/example004-expected.csg b/tests/regression/dumptest/example004-expected.csg new file mode 100644 index 0000000..606d9a6 --- /dev/null +++ b/tests/regression/dumptest/example004-expected.csg @@ -0,0 +1,8 @@ +group() { + group() { + difference() { + cube(size = [30, 30, 30], center = true); + sphere($fn = 0, $fa = 12, $fs = 2, r = 20); + } + } +} diff --git a/tests/regression/dumptest/example004-expected.txt b/tests/regression/dumptest/example004-expected.txt deleted file mode 100644 index 9fda7fe..0000000 --- a/tests/regression/dumptest/example004-expected.txt +++ /dev/null @@ -1,7 +0,0 @@ - group() { - difference() { - cube(size = [30, 30, 30], center = true); - sphere($fn = 0, $fa = 12, $fs = 2, r = 20); - } - } - diff --git a/tests/regression/dumptest/example005-expected.csg b/tests/regression/dumptest/example005-expected.csg new file mode 100644 index 0000000..99c017d --- /dev/null +++ b/tests/regression/dumptest/example005-expected.csg @@ -0,0 +1,44 @@ +group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -120], [0, 0, 0, 1]]) { + difference() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 50, r1 = 100, r2 = 100, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 50, r1 = 80, r2 = 80, center = false); + } + multmatrix([[1, 0, 0, 100], [0, 1, 0, 0], [0, 0, 1, 35], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + } + group() { + group(); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 80], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); + } + group(); + multmatrix([[1, 0, 0, 69.282], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); + } + group(); + multmatrix([[1, 0, 0, 69.282], [0, 1, 0, -40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); + } + group(); + multmatrix([[1, 0, 0, 9.79717e-15], [0, 1, 0, -80], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); + } + group(); + multmatrix([[1, 0, 0, -69.282], [0, 1, 0, -40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); + } + group(); + multmatrix([[1, 0, 0, -69.282], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 200], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 120, r2 = 0, center = false); + } + } + } +} diff --git a/tests/regression/dumptest/example005-expected.txt b/tests/regression/dumptest/example005-expected.txt deleted file mode 100644 index e584aa7..0000000 --- a/tests/regression/dumptest/example005-expected.txt +++ /dev/null @@ -1,43 +0,0 @@ - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -120], [0, 0, 0, 1]]) { - difference() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 50, r1 = 100, r2 = 100, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 50, r1 = 80, r2 = 80, center = false); - } - multmatrix([[1, 0, 0, 100], [0, 1, 0, 0], [0, 0, 1, 35], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - } - group() { - group(); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 80], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); - } - group(); - multmatrix([[1, 0, 0, 69.282], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); - } - group(); - multmatrix([[1, 0, 0, 69.282], [0, 1, 0, -40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); - } - group(); - multmatrix([[1, 0, 0, 9.79717e-15], [0, 1, 0, -80], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); - } - group(); - multmatrix([[1, 0, 0, -69.282], [0, 1, 0, -40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); - } - group(); - multmatrix([[1, 0, 0, -69.282], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 200, r1 = 10, r2 = 10, center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 200], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 120, r2 = 0, center = false); - } - } - } - diff --git a/tests/regression/dumptest/example006-expected.csg b/tests/regression/dumptest/example006-expected.csg new file mode 100644 index 0000000..72ac87b --- /dev/null +++ b/tests/regression/dumptest/example006-expected.csg @@ -0,0 +1,374 @@ +group() { + group() { + difference() { + cube(size = [100, 100, 100], center = true); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + } + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, -20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, 1, 0], [0, -1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example006-expected.txt b/tests/regression/dumptest/example006-expected.txt deleted file mode 100644 index 467ccbc..0000000 --- a/tests/regression/dumptest/example006-expected.txt +++ /dev/null @@ -1,373 +0,0 @@ - group() { - difference() { - cube(size = [100, 100, 100], center = true); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - } - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, -40], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, -20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, 1, 0], [0, -1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, -25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 25], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/example007-expected.csg b/tests/regression/dumptest/example007-expected.csg new file mode 100644 index 0000000..cc4d4fa --- /dev/null +++ b/tests/regression/dumptest/example007-expected.csg @@ -0,0 +1,47 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { + group() { + difference() { + rotate_extrude(file = "example007.dxf", layer = "dorn", origin = [0, 0], scale = 1, convexity = 3, $fn = 0, $fa = 12, $fs = 1); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + intersection() { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { + linear_extrude(file = "example007.dxf", layer = "cutout1", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); + } + } + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { + linear_extrude(file = "example007.dxf", layer = "cutout2", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 2, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } + } + } + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + intersection() { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { + linear_extrude(file = "example007.dxf", layer = "cutout1", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); + } + } + multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { + linear_extrude(file = "example007.dxf", layer = "cutout2", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 2, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example007-expected.txt b/tests/regression/dumptest/example007-expected.txt deleted file mode 100644 index 4e130bd..0000000 --- a/tests/regression/dumptest/example007-expected.txt +++ /dev/null @@ -1,46 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { - group() { - difference() { - rotate_extrude(file = "example007.dxf", layer = "dorn", origin = [0, 0], scale = 1, convexity = 3, $fn = 0, $fa = 12, $fs = 1); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - intersection() { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { - linear_extrude(file = "example007.dxf", layer = "cutout1", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); - } - } - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { - linear_extrude(file = "example007.dxf", layer = "cutout2", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 2, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - } - } - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - intersection() { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { - linear_extrude(file = "example007.dxf", layer = "cutout1", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); - } - } - multmatrix([[6.12323e-17, -1, 0, 0], [1, 6.12323e-17, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -50], [0, 0, 0, 1]]) { - linear_extrude(file = "example007.dxf", layer = "cutout2", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 2, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/example008-expected.csg b/tests/regression/dumptest/example008-expected.csg new file mode 100644 index 0000000..f9116e7 --- /dev/null +++ b/tests/regression/dumptest/example008-expected.csg @@ -0,0 +1,29 @@ +group() { + difference() { + intersection() { + multmatrix([[1, 0, 0, -25], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) { + linear_extrude(file = "example008.dxf", layer = "G", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 3, $fn = 0, $fa = 12, $fs = 1); + } + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -25], [0, 1, 0, -125], [0, 0, 1, -25], [0, 0, 0, 1]]) { + linear_extrude(file = "example008.dxf", layer = "E", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 3, $fn = 0, $fa = 12, $fs = 1); + } + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -125], [0, 1, 0, -125], [0, 0, 1, -25], [0, 0, 0, 1]]) { + linear_extrude(file = "example008.dxf", layer = "B", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 3, $fn = 0, $fa = 12, $fs = 1); + } + } + } + intersection() { + multmatrix([[1, 0, 0, -125], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) { + linear_extrude(file = "example008.dxf", layer = "X", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -125], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) { + linear_extrude(file = "example008.dxf", layer = "X", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } +} diff --git a/tests/regression/dumptest/example008-expected.txt b/tests/regression/dumptest/example008-expected.txt deleted file mode 100644 index f6d4a4c..0000000 --- a/tests/regression/dumptest/example008-expected.txt +++ /dev/null @@ -1,28 +0,0 @@ - difference() { - intersection() { - multmatrix([[1, 0, 0, -25], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) { - linear_extrude(file = "example008.dxf", layer = "G", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 3, $fn = 0, $fa = 12, $fs = 1); - } - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -25], [0, 1, 0, -125], [0, 0, 1, -25], [0, 0, 0, 1]]) { - linear_extrude(file = "example008.dxf", layer = "E", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 3, $fn = 0, $fa = 12, $fs = 1); - } - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -125], [0, 1, 0, -125], [0, 0, 1, -25], [0, 0, 0, 1]]) { - linear_extrude(file = "example008.dxf", layer = "B", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 3, $fn = 0, $fa = 12, $fs = 1); - } - } - } - intersection() { - multmatrix([[1, 0, 0, -125], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) { - linear_extrude(file = "example008.dxf", layer = "X", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -125], [0, 1, 0, -25], [0, 0, 1, -25], [0, 0, 0, 1]]) { - linear_extrude(file = "example008.dxf", layer = "X", origin = [0, 0], scale = 1, height = 50, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - diff --git a/tests/regression/dumptest/example009-expected.csg b/tests/regression/dumptest/example009-expected.csg new file mode 100644 index 0000000..5417d6b --- /dev/null +++ b/tests/regression/dumptest/example009-expected.csg @@ -0,0 +1,23 @@ +group() { + %linear_extrude(height = 22, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + import(file = "example009.dxf", layer = "body", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + %group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 12], [0, 0, 0, 1]]) { + linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + import(file = "example009.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -12], [0, 0, 0, 1]]) { + linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + import(file = "example009.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + } + } + intersection() { + linear_extrude(height = 20, center = true, convexity = 10, twist = -57.5288, slices = 4, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + import(file = "example009.dxf", layer = "fan_top", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + rotate_extrude(file = "example009.dxf", layer = "fan_side", origin = [0, -40], scale = 1, convexity = 10, $fn = 0, $fa = 12, $fs = 2); + } +} diff --git a/tests/regression/dumptest/example009-expected.txt b/tests/regression/dumptest/example009-expected.txt deleted file mode 100644 index b4c7bcf..0000000 --- a/tests/regression/dumptest/example009-expected.txt +++ /dev/null @@ -1,22 +0,0 @@ - %linear_extrude(height = 22, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - import(file = "example009.dxf", layer = "body", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - %group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 12], [0, 0, 0, 1]]) { - linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - import(file = "example009.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -12], [0, 0, 0, 1]]) { - linear_extrude(height = 2, center = true, convexity = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - import(file = "example009.dxf", layer = "plate", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - } - } - intersection() { - linear_extrude(height = 20, center = true, convexity = 10, twist = -57.5288, slices = 4, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - import(file = "example009.dxf", layer = "fan_top", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - rotate_extrude(file = "example009.dxf", layer = "fan_side", origin = [0, -40], scale = 1, convexity = 10, $fn = 0, $fa = 12, $fs = 2); - } - diff --git a/tests/regression/dumptest/example010-expected.csg b/tests/regression/dumptest/example010-expected.csg new file mode 100644 index 0000000..7d9c107 --- /dev/null +++ b/tests/regression/dumptest/example010-expected.csg @@ -0,0 +1,8 @@ +group() { + intersection() { + surface(file = "example010.dat", center = true); + multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + surface(file = "example010.dat", center = true); + } + } +} diff --git a/tests/regression/dumptest/example010-expected.txt b/tests/regression/dumptest/example010-expected.txt deleted file mode 100644 index d0039ef..0000000 --- a/tests/regression/dumptest/example010-expected.txt +++ /dev/null @@ -1,7 +0,0 @@ - intersection() { - surface(file = "example010.dat", center = true); - multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - surface(file = "example010.dat", center = true); - } - } - diff --git a/tests/regression/dumptest/example011-expected.csg b/tests/regression/dumptest/example011-expected.csg new file mode 100644 index 0000000..653a6cf --- /dev/null +++ b/tests/regression/dumptest/example011-expected.csg @@ -0,0 +1,3 @@ +group() { + polyhedron(points = [[10, 0, 0], [0, 10, 0], [-10, 0, 0], [0, -10, 0], [0, 0, 10]], triangles = [[0, 1, 2, 3], [4, 1, 0], [4, 2, 1], [4, 3, 2], [4, 0, 3]], convexity = 1); +} diff --git a/tests/regression/dumptest/example011-expected.txt b/tests/regression/dumptest/example011-expected.txt deleted file mode 100644 index de56dde..0000000 --- a/tests/regression/dumptest/example011-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - polyhedron(points = [[10, 0, 0], [0, 10, 0], [-10, 0, 0], [0, -10, 0], [0, 0, 10]], triangles = [[0, 1, 2, 3], [4, 1, 0], [4, 2, 1], [4, 3, 2], [4, 0, 3]], convexity = 1); - diff --git a/tests/regression/dumptest/example012-expected.csg b/tests/regression/dumptest/example012-expected.csg new file mode 100644 index 0000000..2f07112 --- /dev/null +++ b/tests/regression/dumptest/example012-expected.csg @@ -0,0 +1,10 @@ +group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 1, r = 20); + multmatrix([[1, 0, 0, -2.92], [0, 1, 0, 0.5], [0, 0, 1, 20], [0, 0, 0, 1]]) { + multmatrix([[-1, 1.22465e-16, 1.49976e-32, 0], [1.22465e-16, 1, 1.22465e-16, 0], [0, 1.22465e-16, -1, 0], [0, 0, 0, 1]]) { + import(file = "example012.stl", layer = "", origin = [0, 0], scale = 1, convexity = 5, $fn = 0, $fa = 12, $fs = 1); + } + } + } +} diff --git a/tests/regression/dumptest/example012-expected.txt b/tests/regression/dumptest/example012-expected.txt deleted file mode 100644 index 808ed51..0000000 --- a/tests/regression/dumptest/example012-expected.txt +++ /dev/null @@ -1,9 +0,0 @@ - difference() { - sphere($fn = 0, $fa = 12, $fs = 1, r = 20); - multmatrix([[1, 0, 0, -2.92], [0, 1, 0, 0.5], [0, 0, 1, 20], [0, 0, 0, 1]]) { - multmatrix([[-1, 1.22465e-16, 1.49976e-32, 0], [1.22465e-16, 1, 1.22465e-16, 0], [0, 1.22465e-16, -1, 0], [0, 0, 0, 1]]) { - import(file = "example012.stl", layer = "", origin = [0, 0], scale = 1, convexity = 5, $fn = 0, $fa = 12, $fs = 1); - } - } - } - diff --git a/tests/regression/dumptest/example013-expected.csg b/tests/regression/dumptest/example013-expected.csg new file mode 100644 index 0000000..af686e2 --- /dev/null +++ b/tests/regression/dumptest/example013-expected.csg @@ -0,0 +1,17 @@ +group() { + intersection() { + linear_extrude(height = 100, center = true, convexity = 3, $fn = 0, $fa = 12, $fs = 2) { + import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[2.22045e-16, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 2.22045e-16, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 100, center = true, convexity = 3, $fn = 0, $fa = 12, $fs = 2) { + import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + } + multmatrix([[1, 0, 0, 0], [0, 2.22045e-16, -1, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 100, center = true, convexity = 3, $fn = 0, $fa = 12, $fs = 2) { + import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + } + } +} diff --git a/tests/regression/dumptest/example013-expected.txt b/tests/regression/dumptest/example013-expected.txt deleted file mode 100644 index d3ddd17..0000000 --- a/tests/regression/dumptest/example013-expected.txt +++ /dev/null @@ -1,16 +0,0 @@ - intersection() { - linear_extrude(height = 100, center = true, convexity = 3, $fn = 0, $fa = 12, $fs = 2) { - import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[2.22045e-16, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 2.22045e-16, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 100, center = true, convexity = 3, $fn = 0, $fa = 12, $fs = 2) { - import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - } - multmatrix([[1, 0, 0, 0], [0, 2.22045e-16, -1, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 100, center = true, convexity = 3, $fn = 0, $fa = 12, $fs = 2) { - import(file = "example013.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - } - } - diff --git a/tests/regression/dumptest/example014-expected.csg b/tests/regression/dumptest/example014-expected.csg new file mode 100644 index 0000000..ae43ad2 --- /dev/null +++ b/tests/regression/dumptest/example014-expected.csg @@ -0,0 +1,16 @@ +group() { + intersection() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + multmatrix([[0.46984631039, 0.88256411925, 0.01802831123, 0], [-0.81379768134, 0.44096961053, -0.37852230637, 0], [-0.34202014332, 0.16317591116, 0.92541657839, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + multmatrix([[0.41721770627, 0.66835566162, -0.61581660836, 0], [0.64245892818, -0.69617191219, -0.32029860173, 0], [-0.64278760968, -0.26200263022, -0.71984631039, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + multmatrix([[0.0190076282, -0.60192849838, 0.7983237394, 0], [0.02926918072, 0.79846077351, 0.60133493846, 0], [-0.99939082701, 0.01193633086, 0.03279479952, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + } +} diff --git a/tests/regression/dumptest/example014-expected.txt b/tests/regression/dumptest/example014-expected.txt deleted file mode 100644 index 2b9e21e..0000000 --- a/tests/regression/dumptest/example014-expected.txt +++ /dev/null @@ -1,15 +0,0 @@ - intersection() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - multmatrix([[0.46984631039, 0.88256411925, 0.01802831123, 0], [-0.81379768134, 0.44096961053, -0.37852230637, 0], [-0.34202014332, 0.16317591116, 0.92541657839, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - multmatrix([[0.41721770627, 0.66835566162, -0.61581660836, 0], [0.64245892818, -0.69617191219, -0.32029860173, 0], [-0.64278760968, -0.26200263022, -0.71984631039, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - multmatrix([[0.0190076282, -0.60192849838, 0.7983237394, 0], [0.02926918072, 0.79846077351, 0.60133493846, 0], [-0.99939082701, 0.01193633086, 0.03279479952, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - } - diff --git a/tests/regression/dumptest/example015-expected.csg b/tests/regression/dumptest/example015-expected.csg new file mode 100644 index 0000000..4eec6a2 --- /dev/null +++ b/tests/regression/dumptest/example015-expected.csg @@ -0,0 +1,30 @@ +group() { + group() { + difference() { + multmatrix([[1, 0, 0, -35], [0, 1, 0, -35], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + union() { + difference() { + square(size = [100, 100], center = true); + square(size = [50, 50], center = true); + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [15, 15], center = true); + } + } + multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [100, 30], center = false); + } + } + } + } + multmatrix([[0.70710678118, 0.70710678118, 0, 0], [-0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[0.7, 0, 0, 0], [0, 1.3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 5); + } + } + } + import(file = "example009.dxf", layer = "body", origin = [0, 0], scale = 2, convexity = 6, $fn = 0, $fa = 12, $fs = 2); + } +} diff --git a/tests/regression/dumptest/example015-expected.txt b/tests/regression/dumptest/example015-expected.txt deleted file mode 100644 index defedcd..0000000 --- a/tests/regression/dumptest/example015-expected.txt +++ /dev/null @@ -1,29 +0,0 @@ - group() { - difference() { - multmatrix([[1, 0, 0, -35], [0, 1, 0, -35], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - union() { - difference() { - square(size = [100, 100], center = true); - square(size = [50, 50], center = true); - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [15, 15], center = true); - } - } - multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [100, 30], center = false); - } - } - } - } - multmatrix([[0.70710678118, 0.70710678118, 0, 0], [-0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[0.7, 0, 0, 0], [0, 1.3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 5); - } - } - } - import(file = "example009.dxf", layer = "body", origin = [0, 0], scale = 2, convexity = 6, $fn = 0, $fa = 12, $fs = 2); - } - diff --git a/tests/regression/dumptest/example016-expected.csg b/tests/regression/dumptest/example016-expected.csg new file mode 100644 index 0000000..a21c353 --- /dev/null +++ b/tests/regression/dumptest/example016-expected.csg @@ -0,0 +1,85 @@ +group() { + difference() { + group() { + cube(size = [65, 28, 28], center = true); + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + render(convexity = 12) { + difference() { + group() { + difference() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { + cube(size = [60, 28, 14], center = true); + } + cube(size = [8, 32, 32], center = true); + } + } + group() { + multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + render(convexity = 12) { + difference() { + group() { + difference() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { + cube(size = [60, 28, 14], center = true); + } + cube(size = [8, 32, 32], center = true); + } + } + group() { + multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, -1, -1.22465e-16, 0], [0, 1.22465e-16, -1, 0], [0, 0, 0, 1]]) { + render(convexity = 12) { + difference() { + group() { + difference() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { + cube(size = [60, 28, 14], center = true); + } + cube(size = [8, 32, 32], center = true); + } + } + group() { + multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, -1.83697e-16, 1, 0], [0, -1, -1.83697e-16, 0], [0, 0, 0, 1]]) { + render(convexity = 12) { + difference() { + group() { + difference() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { + cube(size = [60, 28, 14], center = true); + } + cube(size = [8, 32, 32], center = true); + } + } + group() { + multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example016-expected.txt b/tests/regression/dumptest/example016-expected.txt deleted file mode 100644 index 401a9f9..0000000 --- a/tests/regression/dumptest/example016-expected.txt +++ /dev/null @@ -1,84 +0,0 @@ - difference() { - group() { - cube(size = [65, 28, 28], center = true); - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - render(convexity = 12) { - difference() { - group() { - difference() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { - cube(size = [60, 28, 14], center = true); - } - cube(size = [8, 32, 32], center = true); - } - } - group() { - multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - render(convexity = 12) { - difference() { - group() { - difference() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { - cube(size = [60, 28, 14], center = true); - } - cube(size = [8, 32, 32], center = true); - } - } - group() { - multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, -1, -1.22465e-16, 0], [0, 1.22465e-16, -1, 0], [0, 0, 0, 1]]) { - render(convexity = 12) { - difference() { - group() { - difference() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { - cube(size = [60, 28, 14], center = true); - } - cube(size = [8, 32, 32], center = true); - } - } - group() { - multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, -1.83697e-16, 1, 0], [0, -1, -1.83697e-16, 0], [0, 0, 0, 1]]) { - render(convexity = 12) { - difference() { - group() { - difference() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.5], [0, 0, 0, 1]]) { - cube(size = [60, 28, 14], center = true); - } - cube(size = [8, 32, 32], center = true); - } - } - group() { - multmatrix([[1, 0, 0, -14], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "example016.stl", layer = "", origin = [0, 0], scale = 1, convexity = 12, $fn = 0, $fa = 12, $fs = 1); - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/example017-expected.csg b/tests/regression/dumptest/example017-expected.csg new file mode 100644 index 0000000..2603f40 --- /dev/null +++ b/tests/regression/dumptest/example017-expected.csg @@ -0,0 +1,216 @@ +group() { + group(); + group(); + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 74], [0, 0, 0, 1]]) { + linear_extrude(height = 6, center = false, convexity = 4, $fn = 0, $fa = 12, $fs = 2) { + group() { + difference() { + circle($fn = 0, $fa = 12, $fs = 2, r = 47); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 36], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 10], center = true); + } + } + multmatrix([[-0.5, -0.866025, 0, 0], [0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 36], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 10], center = true); + } + } + multmatrix([[-0.5, 0.866025, 0, 0], [-0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 36], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 10], center = true); + } + } + } + circle($fn = 0, $fa = 12, $fs = 2, r = 25); + } + } + } + } + linear_extrude(height = 6, center = false, convexity = 4, $fn = 0, $fa = 12, $fs = 2) { + group() { + difference() { + circle($fn = 0, $fa = 12, $fs = 2, r = 102); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 88.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 15], center = true); + } + } + multmatrix([[-0.5, -0.866025, 0, 0], [0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 88.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 15], center = true); + } + } + multmatrix([[-0.5, 0.866025, 0, 0], [-0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 88.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 15], center = true); + } + } + } + circle($fn = 0, $fa = 12, $fs = 2, r = 75); + } + } + } + color([0.7, 0.7, 1, 1]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 102], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2.22045e-16, 2.22045e-16, -1, 0], [-1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 6, center = true, convexity = 10, $fn = 0, $fa = 12, $fs = 2) { + group() { + union() { + difference() { + polygon(points = [[0, 6], [6, 6], [6, 0], [21, 0], [21, 6], [27, 6], [27, 0], [77, 0], [83, 12], [77, 18], [77, 74], [71, 74], [71, 80], [61, 80], [61, 74], [55, 74], [55, 80], [49, 74], [49, 18], [43, 12], [6, 12]], paths = undef, convexity = 1); + multmatrix([[1, 0, 0, 43], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + multmatrix([[1, 0, 0, 83], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + } + multmatrix([[1, 0, 0, 77], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [9, 12], center = false); + } + multmatrix([[1, 0, 0, 86], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12, 12], center = false); + } + } + } + multmatrix([[1, 0, 0, 55], [0, 1, 0, 74], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12, 12], center = false); + } + } + } + } + } + } + } + } + } + multmatrix([[-0.5, -0.866025, 0, 0], [0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 102], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2.22045e-16, 2.22045e-16, -1, 0], [-1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 6, center = true, convexity = 10, $fn = 0, $fa = 12, $fs = 2) { + group() { + union() { + difference() { + polygon(points = [[0, 6], [6, 6], [6, 0], [21, 0], [21, 6], [27, 6], [27, 0], [77, 0], [83, 12], [77, 18], [77, 74], [71, 74], [71, 80], [61, 80], [61, 74], [55, 74], [55, 80], [49, 74], [49, 18], [43, 12], [6, 12]], paths = undef, convexity = 1); + multmatrix([[1, 0, 0, 43], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + multmatrix([[1, 0, 0, 83], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + } + multmatrix([[1, 0, 0, 77], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [9, 12], center = false); + } + multmatrix([[1, 0, 0, 86], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12, 12], center = false); + } + } + } + multmatrix([[1, 0, 0, 55], [0, 1, 0, 74], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12, 12], center = false); + } + } + } + } + } + } + } + } + } + multmatrix([[-0.5, 0.866025, 0, 0], [-0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 102], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2.22045e-16, 2.22045e-16, -1, 0], [-1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 6, center = true, convexity = 10, $fn = 0, $fa = 12, $fs = 2) { + group() { + union() { + difference() { + polygon(points = [[0, 6], [6, 6], [6, 0], [21, 0], [21, 6], [27, 6], [27, 0], [77, 0], [83, 12], [77, 18], [77, 74], [71, 74], [71, 80], [61, 80], [61, 74], [55, 74], [55, 80], [49, 74], [49, 18], [43, 12], [6, 12]], paths = undef, convexity = 1); + multmatrix([[1, 0, 0, 43], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + multmatrix([[1, 0, 0, 83], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + } + multmatrix([[1, 0, 0, 77], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [9, 12], center = false); + } + multmatrix([[1, 0, 0, 86], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12, 12], center = false); + } + } + } + multmatrix([[1, 0, 0, 55], [0, 1, 0, 74], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + circle($fn = 0, $fa = 12, $fs = 2, r = 6); + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12, 12], center = false); + } + } + } + } + } + } + } + } + } + } + } + %multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 12], [0, 0, 0, 1]]) { + group() { + rotate_extrude(convexity = 2, $fn = 0, $fa = 12, $fs = 2) { + square(size = [25, 68], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 68], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + square(size = [25, 25], center = false); + multmatrix([[1, 0, 0, 0], [0, 0.7, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 25); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 93], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -12.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [12.5, 25], center = false); + } + circle($fn = 0, $fa = 12, $fs = 2, r = 12.5); + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example017-expected.txt b/tests/regression/dumptest/example017-expected.txt deleted file mode 100644 index a27ed75..0000000 --- a/tests/regression/dumptest/example017-expected.txt +++ /dev/null @@ -1,215 +0,0 @@ - group(); - group(); - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 74], [0, 0, 0, 1]]) { - linear_extrude(height = 6, center = false, convexity = 4, $fn = 0, $fa = 12, $fs = 2) { - group() { - difference() { - circle($fn = 0, $fa = 12, $fs = 2, r = 47); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 36], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 10], center = true); - } - } - multmatrix([[-0.5, -0.866025, 0, 0], [0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 36], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 10], center = true); - } - } - multmatrix([[-0.5, 0.866025, 0, 0], [-0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 36], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 10], center = true); - } - } - } - circle($fn = 0, $fa = 12, $fs = 2, r = 25); - } - } - } - } - linear_extrude(height = 6, center = false, convexity = 4, $fn = 0, $fa = 12, $fs = 2) { - group() { - difference() { - circle($fn = 0, $fa = 12, $fs = 2, r = 102); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 88.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 15], center = true); - } - } - multmatrix([[-0.5, -0.866025, 0, 0], [0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 88.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 15], center = true); - } - } - multmatrix([[-0.5, 0.866025, 0, 0], [-0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 88.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 15], center = true); - } - } - } - circle($fn = 0, $fa = 12, $fs = 2, r = 75); - } - } - } - color([0.7, 0.7, 1, 1]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 102], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2.22045e-16, 2.22045e-16, -1, 0], [-1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 6, center = true, convexity = 10, $fn = 0, $fa = 12, $fs = 2) { - group() { - union() { - difference() { - polygon(points = [[0, 6], [6, 6], [6, 0], [21, 0], [21, 6], [27, 6], [27, 0], [77, 0], [83, 12], [77, 18], [77, 74], [71, 74], [71, 80], [61, 80], [61, 74], [55, 74], [55, 80], [49, 74], [49, 18], [43, 12], [6, 12]], paths = undef, convexity = 1); - multmatrix([[1, 0, 0, 43], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - multmatrix([[1, 0, 0, 83], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - } - multmatrix([[1, 0, 0, 77], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [9, 12], center = false); - } - multmatrix([[1, 0, 0, 86], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12, 12], center = false); - } - } - } - multmatrix([[1, 0, 0, 55], [0, 1, 0, 74], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12, 12], center = false); - } - } - } - } - } - } - } - } - } - multmatrix([[-0.5, -0.866025, 0, 0], [0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 102], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2.22045e-16, 2.22045e-16, -1, 0], [-1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 6, center = true, convexity = 10, $fn = 0, $fa = 12, $fs = 2) { - group() { - union() { - difference() { - polygon(points = [[0, 6], [6, 6], [6, 0], [21, 0], [21, 6], [27, 6], [27, 0], [77, 0], [83, 12], [77, 18], [77, 74], [71, 74], [71, 80], [61, 80], [61, 74], [55, 74], [55, 80], [49, 74], [49, 18], [43, 12], [6, 12]], paths = undef, convexity = 1); - multmatrix([[1, 0, 0, 43], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - multmatrix([[1, 0, 0, 83], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - } - multmatrix([[1, 0, 0, 77], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [9, 12], center = false); - } - multmatrix([[1, 0, 0, 86], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12, 12], center = false); - } - } - } - multmatrix([[1, 0, 0, 55], [0, 1, 0, 74], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12, 12], center = false); - } - } - } - } - } - } - } - } - } - multmatrix([[-0.5, 0.866025, 0, 0], [-0.866025, -0.5, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 102], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2.22045e-16, 2.22045e-16, -1, 0], [-1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 6, center = true, convexity = 10, $fn = 0, $fa = 12, $fs = 2) { - group() { - union() { - difference() { - polygon(points = [[0, 6], [6, 6], [6, 0], [21, 0], [21, 6], [27, 6], [27, 0], [77, 0], [83, 12], [77, 18], [77, 74], [71, 74], [71, 80], [61, 80], [61, 74], [55, 74], [55, 80], [49, 74], [49, 18], [43, 12], [6, 12]], paths = undef, convexity = 1); - multmatrix([[1, 0, 0, 43], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - multmatrix([[1, 0, 0, 83], [0, 1, 0, 18], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - } - multmatrix([[1, 0, 0, 77], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [9, 12], center = false); - } - multmatrix([[1, 0, 0, 86], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12, 12], center = false); - } - } - } - multmatrix([[1, 0, 0, 55], [0, 1, 0, 74], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - circle($fn = 0, $fa = 12, $fs = 2, r = 6); - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12, 12], center = false); - } - } - } - } - } - } - } - } - } - } - } - %multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 12], [0, 0, 0, 1]]) { - group() { - rotate_extrude(convexity = 2, $fn = 0, $fa = 12, $fs = 2) { - square(size = [25, 68], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 68], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - square(size = [25, 25], center = false); - multmatrix([[1, 0, 0, 0], [0, 0.7, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 25); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 93], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -12.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [12.5, 25], center = false); - } - circle($fn = 0, $fa = 12, $fs = 2, r = 12.5); - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/example018-expected.csg b/tests/regression/dumptest/example018-expected.csg new file mode 100644 index 0000000..7f13f40 --- /dev/null +++ b/tests/regression/dumptest/example018-expected.csg @@ -0,0 +1,120 @@ +group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -150], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [60, 60, 60], center = true); + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [45, 45, 45], center = true); + multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + } + } + multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 30); + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [45, 45, 45], center = true); + multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 30); + } + multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [60, 60, 60], center = true); + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [45, 45, 45], center = true); + multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 30); + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [60, 60, 60], center = true); + } + multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 150], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 30); + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [60, 60, 60], center = true); + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); + } + multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [45, 45, 45], center = true); + multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [50, 50, 50], center = true); + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example018-expected.txt b/tests/regression/dumptest/example018-expected.txt deleted file mode 100644 index 9e6ee4f..0000000 --- a/tests/regression/dumptest/example018-expected.txt +++ /dev/null @@ -1,119 +0,0 @@ - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -150], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [60, 60, 60], center = true); - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [45, 45, 45], center = true); - multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - } - } - multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 30); - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [45, 45, 45], center = true); - multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 30); - } - multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [60, 60, 60], center = true); - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [45, 45, 45], center = true); - multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 30); - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [60, 60, 60], center = true); - } - multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 150], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[1, 0, 0, -150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 30); - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [60, 60, 60], center = true); - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 50, r1 = 30, r2 = 30, center = true); - } - multmatrix([[1, 0, 0, 150], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [45, 45, 45], center = true); - multmatrix([[1, 0, 0, 0], [0, 0.70710678118, -0.70710678118, 0], [0, 0.70710678118, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, 0, 0.70710678118, 0], [0, 1, 0, 0], [-0.70710678118, 0, 0.70710678118, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - multmatrix([[0.70710678118, -0.70710678118, 0, 0], [0.70710678118, 0.70710678118, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [50, 50, 50], center = true); - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/example019-expected.csg b/tests/regression/dumptest/example019-expected.csg new file mode 100644 index 0000000..8e078ed --- /dev/null +++ b/tests/regression/dumptest/example019-expected.csg @@ -0,0 +1,127 @@ +group() { + group() { + multmatrix([[1, 0, 0, -100], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 45, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -95], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 46.5, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -90], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 48, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -85], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 49.5, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -80], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 51, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -75], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 52.5, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -70], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 54, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -65], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 55.5, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -60], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 57, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -55], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 58.5, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 60, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -45], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 59, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -40], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 58, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -35], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 57, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 56, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 55, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 54, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -15], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 55.05, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 56.1, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, -5], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 57.15, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 58.2, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 59.25, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 60.3, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 61.35, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 62.4, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 63.45, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 64.5, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 35], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 65.55, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 40], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 66.6, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 45], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 67.65, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 68.7, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 55], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 69.75, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 60], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 70.8, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 65], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 71.85, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 70], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 72.9, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 75], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 73.95, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 80], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 75, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 85], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 70.0714, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 90], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 65.1429, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 95], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 60.2143, r1 = 6, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 100], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 55.2857, r1 = 6, r2 = 2, center = false); + } + } +} diff --git a/tests/regression/dumptest/example019-expected.txt b/tests/regression/dumptest/example019-expected.txt deleted file mode 100644 index 47406e6..0000000 --- a/tests/regression/dumptest/example019-expected.txt +++ /dev/null @@ -1,126 +0,0 @@ - group() { - multmatrix([[1, 0, 0, -100], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 45, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -95], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 46.5, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -90], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 48, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -85], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 49.5, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -80], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 51, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -75], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 52.5, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -70], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 54, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -65], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 55.5, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -60], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 57, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -55], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 58.5, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 60, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -45], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 59, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -40], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 58, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -35], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 57, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 56, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 55, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 54, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -15], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 55.05, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 56.1, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, -5], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 57.15, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 58.2, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 59.25, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 60.3, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 61.35, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 62.4, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 63.45, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 64.5, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 35], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 65.55, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 40], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 66.6, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 45], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 67.65, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 68.7, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 55], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 69.75, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 60], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 70.8, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 65], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 71.85, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 70], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 72.9, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 75], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 73.95, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 80], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 75, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 85], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 70.0714, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 90], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 65.1429, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 95], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 60.2143, r1 = 6, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 100], [0, 1, 0, 0], [0, 0, 1, -30], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 55.2857, r1 = 6, r2 = 2, center = false); - } - } - diff --git a/tests/regression/dumptest/example020-expected.csg b/tests/regression/dumptest/example020-expected.csg new file mode 100644 index 0000000..07d4ff4 --- /dev/null +++ b/tests/regression/dumptest/example020-expected.csg @@ -0,0 +1,233 @@ +group() { + multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + linear_extrude(height = 100, center = false, convexity = 8, twist = 411.429, slices = 34, $fn = 0, $fa = 12, $fs = 1) { + difference() { + circle($fn = 0, $fa = 12, $fs = 1, r = 20); + group() { + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[0.62349, -0.781831, 0, 0], [0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.222521, -0.974928, 0, 0], [0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.900969, -0.433884, 0, 0], [0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.900969, 0.433884, 0, 0], [-0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.222521, 0.974928, 0, 0], [-0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[0.62349, 0.781831, 0, 0], [-0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cylinder($fn = 6, $fa = 12, $fs = 1, h = 20, r1 = 30, r2 = 30, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { + group() { + linear_extrude(height = 40, center = false, convexity = 3, twist = 164.571, slices = 13, $fn = 0, $fa = 12, $fs = 1) { + difference() { + circle($fn = 0, $fa = 12, $fs = 1, r = 21); + group() { + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[0.62349, -0.781831, 0, 0], [0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.222521, -0.974928, 0, 0], [0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.900969, -0.433884, 0, 0], [0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.900969, 0.433884, 0, 0], [-0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[-0.222521, 0.974928, 0, 0], [-0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + group(); + group() { + multmatrix([[0.62349, 0.781831, 0, 0], [-0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); + } + } + } + } + } + } + } + } + } + } + group() { + linear_extrude(height = 100, center = false, convexity = 5, twist = 1500, slices = 79, $fn = 19.2, $fa = 12, $fs = 1) { + group() { + group() { + group() { + polygon(points = [[100, 0], [90.10870717256485, 30.58778441039996], [99.27731872645629, 33.70010865023236]], paths = undef, convexity = 1); + } + group(); + group(); + } + group() { + group(); + group(); + group() { + polygon(points = [[99.27731872645629, 33.70010865023236], [90.10870717256485, 30.58778441039996], [74.08779492859099, 56.84956452855862], [84.58287312965604, 64.90272127318551]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[84.58287312965604, 64.90272127318551], [74.08779492859099, 56.84956452855862], [51.22010456048879, 76.65630364955641], [59.89394204343166, 89.63761881095262]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[59.89394204343166, 89.63761881095262], [51.22010456048879, 76.65630364955641], [23.64046582983194, 88.22741959152876], [28.12334319067221, 104.9577456662849]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[28.12334319067221, 104.9577456662849], [23.64046582983194, 88.22741959152876], [-5.934009687954409, 90.53549252778905], [-7.146616158074179, 109.0362921199316]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-7.146616158074179, 109.0362921199316], [-5.934009687954409, 90.53549252778905], [-34.56302683546026, 83.44252814283341], [-41.97365963755769, 101.3333783594239]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-41.97365963755769, 101.3333783594239], [-34.56302683546026, 83.44252814283341], [-59.39283755470954, 67.72455141159254], [-72.47632546530423, 82.64341008420294]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-72.47632546530423, 82.64341008420294], [-59.39283755470954, 67.72455141159254], [-77.94228634059948, 44.99999999999999], [-95.26279441628826, 54.99999999999999]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-95.26279441628826, 54.99999999999999], [-77.94228634059948, 44.99999999999999], [-88.34760075969918, 17.57343041942462], [-107.8094553209469, 21.444633983801]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-107.8094553209469, 21.444633983801], [-88.34760075969918, 17.57343041942462], [-89.54486254542182, -11.78880480022482], [-108.7441097293403, -14.31643364378545]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-108.7441097293403, -14.31643364378545], [-89.54486254542182, -11.78880480022482], [-81.37304131717875, -40.12874312782305], [-98.0015069893589, -48.32899491597725]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-98.0015069893589, -48.32899491597725], [-81.37304131717875, -40.12874312782305], [-64.58695376169682, -64.5869537616968], [-76.83440247561271, -76.83440247561269]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-76.83440247561271, -76.83440247561269], [-64.58695376169682, -64.5869537616968], [-40.77625404048524, -82.68606355865667], [-47.68148400331503, -96.68848474788098]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-47.68148400331503, -96.68848474788098], [-40.77625404048524, -82.68606355865667], [-12.18926961151899, -92.58669478281102], [-13.91596883249134, -105.7022774919511]], paths = undef, convexity = 1); + } + } + group() { + group(); + group(); + group() { + polygon(points = [[-13.91596883249134, -105.7022774919511], [-12.18926961151899, -92.58669478281102], [18.56455524139444, -93.33032171881419], [20.45350916183121, -102.8267343618319]], paths = undef, convexity = 1); + } + } + group() { + group(); + group() { + polygon(points = [[20.45350916183121, -102.8267343618319], [18.56455524139444, -93.33032171881419], [50, -86.60254037844386]], paths = undef, convexity = 1); + } + group(); + } + } + } + } +} diff --git a/tests/regression/dumptest/example020-expected.txt b/tests/regression/dumptest/example020-expected.txt deleted file mode 100644 index 733f1e1..0000000 --- a/tests/regression/dumptest/example020-expected.txt +++ /dev/null @@ -1,232 +0,0 @@ - multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - linear_extrude(height = 100, center = false, convexity = 8, twist = 411.429, slices = 34, $fn = 0, $fa = 12, $fs = 1) { - difference() { - circle($fn = 0, $fa = 12, $fs = 1, r = 20); - group() { - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[0.62349, -0.781831, 0, 0], [0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.222521, -0.974928, 0, 0], [0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.900969, -0.433884, 0, 0], [0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.900969, 0.433884, 0, 0], [-0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.222521, 0.974928, 0, 0], [-0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[0.62349, 0.781831, 0, 0], [-0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[40, 0], [20, 0], [14.62391868272735, 3.337814009344716], [13.51453301853629, 6.508256086763372], [15.6366296493606, 12.46979603717467], [31.27325929872119, 24.93959207434934]], paths = undef, convexity = 1); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cylinder($fn = 6, $fa = 12, $fs = 1, h = 20, r1 = 30, r2 = 30, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { - group() { - linear_extrude(height = 40, center = false, convexity = 3, twist = 164.571, slices = 13, $fn = 0, $fa = 12, $fs = 1) { - difference() { - circle($fn = 0, $fa = 12, $fs = 1, r = 21); - group() { - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[0.62349, -0.781831, 0, 0], [0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.222521, -0.974928, 0, 0], [0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.900969, -0.433884, 0, 0], [0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.900969, 0.433884, 0, 0], [-0.433884, -0.900969, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[-0.222521, 0.974928, 0, 0], [-0.974928, -0.222521, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - group(); - group() { - multmatrix([[0.62349, 0.781831, 0, 0], [-0.781831, 0.62349, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[42, 0], [21, 0], [15.59884659490918, 3.56033494330103], [14.41550188643871, 6.94213982588093], [16.41846113182863, 13.0932858390334], [32.83692226365725, 26.18657167806681]], paths = undef, convexity = 1); - } - } - } - } - } - } - } - } - } - } - group() { - linear_extrude(height = 100, center = false, convexity = 5, twist = 1500, slices = 79, $fn = 19.2, $fa = 12, $fs = 1) { - group() { - group() { - group() { - polygon(points = [[100, 0], [90.10870717256485, 30.58778441039996], [99.27731872645629, 33.70010865023236]], paths = undef, convexity = 1); - } - group(); - group(); - } - group() { - group(); - group(); - group() { - polygon(points = [[99.27731872645629, 33.70010865023236], [90.10870717256485, 30.58778441039996], [74.08779492859099, 56.84956452855862], [84.58287312965604, 64.90272127318551]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[84.58287312965604, 64.90272127318551], [74.08779492859099, 56.84956452855862], [51.22010456048879, 76.65630364955641], [59.89394204343166, 89.63761881095262]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[59.89394204343166, 89.63761881095262], [51.22010456048879, 76.65630364955641], [23.64046582983194, 88.22741959152876], [28.12334319067221, 104.9577456662849]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[28.12334319067221, 104.9577456662849], [23.64046582983194, 88.22741959152876], [-5.934009687954409, 90.53549252778905], [-7.146616158074179, 109.0362921199316]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-7.146616158074179, 109.0362921199316], [-5.934009687954409, 90.53549252778905], [-34.56302683546026, 83.44252814283341], [-41.97365963755769, 101.3333783594239]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-41.97365963755769, 101.3333783594239], [-34.56302683546026, 83.44252814283341], [-59.39283755470954, 67.72455141159254], [-72.47632546530423, 82.64341008420294]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-72.47632546530423, 82.64341008420294], [-59.39283755470954, 67.72455141159254], [-77.94228634059948, 44.99999999999999], [-95.26279441628826, 54.99999999999999]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-95.26279441628826, 54.99999999999999], [-77.94228634059948, 44.99999999999999], [-88.34760075969918, 17.57343041942462], [-107.8094553209469, 21.444633983801]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-107.8094553209469, 21.444633983801], [-88.34760075969918, 17.57343041942462], [-89.54486254542182, -11.78880480022482], [-108.7441097293403, -14.31643364378545]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-108.7441097293403, -14.31643364378545], [-89.54486254542182, -11.78880480022482], [-81.37304131717875, -40.12874312782305], [-98.0015069893589, -48.32899491597725]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-98.0015069893589, -48.32899491597725], [-81.37304131717875, -40.12874312782305], [-64.58695376169682, -64.5869537616968], [-76.83440247561271, -76.83440247561269]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-76.83440247561271, -76.83440247561269], [-64.58695376169682, -64.5869537616968], [-40.77625404048524, -82.68606355865667], [-47.68148400331503, -96.68848474788098]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-47.68148400331503, -96.68848474788098], [-40.77625404048524, -82.68606355865667], [-12.18926961151899, -92.58669478281102], [-13.91596883249134, -105.7022774919511]], paths = undef, convexity = 1); - } - } - group() { - group(); - group(); - group() { - polygon(points = [[-13.91596883249134, -105.7022774919511], [-12.18926961151899, -92.58669478281102], [18.56455524139444, -93.33032171881419], [20.45350916183121, -102.8267343618319]], paths = undef, convexity = 1); - } - } - group() { - group(); - group() { - polygon(points = [[20.45350916183121, -102.8267343618319], [18.56455524139444, -93.33032171881419], [50, -86.60254037844386]], paths = undef, convexity = 1); - } - group(); - } - } - } - } - diff --git a/tests/regression/dumptest/example021-expected.csg b/tests/regression/dumptest/example021-expected.csg new file mode 100644 index 0000000..964621c --- /dev/null +++ b/tests/regression/dumptest/example021-expected.csg @@ -0,0 +1,268 @@ +group() { + multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = false, convexity = 0) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -20], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 15], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -15], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 5], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -5], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -5], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 5], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -15], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 15], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -20], [0, 0, 0, 1]]) { + linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } + } + } + } + } + } + group() { + difference() { + sphere($fn = 0, $fa = 30, $fs = 1, r = 25); + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example021-expected.txt b/tests/regression/dumptest/example021-expected.txt deleted file mode 100644 index 8122a9d..0000000 --- a/tests/regression/dumptest/example021-expected.txt +++ /dev/null @@ -1,267 +0,0 @@ - multmatrix([[1, 0, 0, -30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = false, convexity = 0) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -20], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 15], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -15], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 5], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -5], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -5], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 5], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -15], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 15], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - multmatrix([[0.933013, 0.0669873, -0.353553, 0], [0.0669873, 0.933013, 0.353553, 0], [0.353553, -0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -20], [0, 0, 0, 1]]) { - linear_extrude(height = 0.5, center = true, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - multmatrix([[0.933013, 0.0669873, 0.353553, 0], [0.0669873, 0.933013, -0.353553, 0], [-0.353553, 0.353553, 0.866025, 0], [0, 0, 0, 1]]) { - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - } - } - } - } - } - group() { - difference() { - sphere($fn = 0, $fa = 30, $fs = 1, r = 25); - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - multmatrix([[1, 0, 0, 0], [0, 6.12323e-17, -1, 0], [0, 1, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - multmatrix([[6.12323e-17, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 6.12323e-17, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 30, $fs = 1, h = 62.5, r1 = 12.5, r2 = 6.25, center = true); - } - } - } - } - } - diff --git a/tests/regression/dumptest/example022-expected.csg b/tests/regression/dumptest/example022-expected.csg new file mode 100644 index 0000000..9c9eaa2 --- /dev/null +++ b/tests/regression/dumptest/example022-expected.csg @@ -0,0 +1,127 @@ +group() { + multmatrix([[1, 0, 0, -15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + cube(size = [10, 30, 40], center = true); + cube(size = [20, 20, 40], center = true); + group() { + multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); + } + multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); + } + } + } + } + } + multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + cube(size = [20, 20, 30], center = true); + cube(size = [10, 30, 30], center = true); + cube(size = [10, 20, 40], center = true); + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); + } + } + } + group() { + multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -10], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -10], [0, 1, 0, 15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 10], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 10], [0, 1, 0, 15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); + } + } + } + group() { + multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -15], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, -15], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 15], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); + } + } + multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, -15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, 15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, -15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, 15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, -15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, 15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, -15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 15], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + } + } + } + } +} diff --git a/tests/regression/dumptest/example022-expected.txt b/tests/regression/dumptest/example022-expected.txt deleted file mode 100644 index bd200f8..0000000 --- a/tests/regression/dumptest/example022-expected.txt +++ /dev/null @@ -1,126 +0,0 @@ - multmatrix([[1, 0, 0, -15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - cube(size = [10, 30, 40], center = true); - cube(size = [20, 20, 40], center = true); - group() { - multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); - } - multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 40, r1 = 5, r2 = 5, center = true); - } - } - } - } - } - multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - cube(size = [20, 20, 30], center = true); - cube(size = [10, 30, 30], center = true); - cube(size = [10, 20, 40], center = true); - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 5, r2 = 5, center = true); - } - } - } - group() { - multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -10], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -10], [0, 1, 0, 15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 10], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[2.22045e-16, -2.22045e-16, 1, 0], [1, 0, -2.22045e-16, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 10], [0, 1, 0, 15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 5, r2 = 5, center = true); - } - } - } - group() { - multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -15], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, -15], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 15], [0, 1, 0, -5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); - } - } - multmatrix([[2.22045e-16, 1, 2.22045e-16, 0], [0, 2.22045e-16, -1, 0], [-1, 2.22045e-16, 0, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 20, r1 = 5, r2 = 5, center = true); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, -15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, -5], [0, 1, 0, -10], [0, 0, 1, 15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, -15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, -5], [0, 1, 0, 10], [0, 0, 1, 15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, -15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, -10], [0, 0, 1, 15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, -15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 15], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - } - } - } - } - diff --git a/tests/regression/dumptest/example024-expected.csg b/tests/regression/dumptest/example024-expected.csg new file mode 100644 index 0000000..8755567 --- /dev/null +++ b/tests/regression/dumptest/example024-expected.csg @@ -0,0 +1,1870 @@ +group() { + difference() { + multmatrix([[0.81649658092, 0.40824829046, 0.40824829046, 0], [0, 0.70710678118, -0.70710678118, 0], [-0.57735026919, 0.57735026919, 0.57735026919, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cube(size = [100, 100, 100], center = true); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 33.3333, 33.3333], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + } + } + } + } + multmatrix([[0, -1, 0, 0], [1, 0, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 33.3333, 33.3333], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + } + } + } + } + multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 33.3333, 33.3333], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 11.1111, 11.1111], center = true); + group() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group(); + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { + group() { + cube(size = [110, 3.7037, 3.7037], center = true); + group(); + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -100], [0, 0, 0, 1]]) { + cube(size = [200, 200, 200], center = true); + } + } +} diff --git a/tests/regression/dumptest/example024-expected.txt b/tests/regression/dumptest/example024-expected.txt deleted file mode 100644 index e7d6e8b..0000000 --- a/tests/regression/dumptest/example024-expected.txt +++ /dev/null @@ -1,1869 +0,0 @@ - difference() { - multmatrix([[0.81649658092, 0.40824829046, 0.40824829046, 0], [0, 0.70710678118, -0.70710678118, 0], [-0.57735026919, 0.57735026919, 0.57735026919, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cube(size = [100, 100, 100], center = true); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 33.3333, 33.3333], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - } - } - } - } - multmatrix([[0, -1, 0, 0], [1, 0, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 33.3333, 33.3333], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - } - } - } - } - multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 33.3333, 33.3333], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, -33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 33.33333333333], [0, 0, 1, 33.33333333333], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 11.1111, 11.1111], center = true); - group() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group(); - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, -11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11.11111111111], [0, 0, 1, 11.11111111111], [0, 0, 0, 1]]) { - group() { - cube(size = [110, 3.7037, 3.7037], center = true); - group(); - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -100], [0, 0, 0, 1]]) { - cube(size = [200, 200, 200], center = true); - } - } - diff --git a/tests/regression/dumptest/for-expected.csg b/tests/regression/dumptest/for-expected.csg new file mode 100644 index 0000000..434cc8f --- /dev/null +++ b/tests/regression/dumptest/for-expected.csg @@ -0,0 +1,3 @@ +group() { + group(); +} diff --git a/tests/regression/dumptest/for-expected.txt b/tests/regression/dumptest/for-expected.txt deleted file mode 100644 index b2915cb..0000000 --- a/tests/regression/dumptest/for-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - group(); - diff --git a/tests/regression/dumptest/for-nested-tests-expected.csg b/tests/regression/dumptest/for-nested-tests-expected.csg new file mode 100644 index 0000000..7ab595c --- /dev/null +++ b/tests/regression/dumptest/for-nested-tests-expected.csg @@ -0,0 +1,112 @@ +group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } +} diff --git a/tests/regression/dumptest/for-nested-tests-expected.txt b/tests/regression/dumptest/for-nested-tests-expected.txt deleted file mode 100644 index d1034b3..0000000 --- a/tests/regression/dumptest/for-nested-tests-expected.txt +++ /dev/null @@ -1,111 +0,0 @@ - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 0], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 5], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 5], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 10], [0, 0, 1, 20], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, 10], [0, 0, 1, 30], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - diff --git a/tests/regression/dumptest/for-tests-expected.csg b/tests/regression/dumptest/for-tests-expected.csg new file mode 100644 index 0000000..7aa29d7 --- /dev/null +++ b/tests/regression/dumptest/for-tests-expected.csg @@ -0,0 +1,115 @@ +group() { + group(); + group(); + multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group(); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); + } + } + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 4, r2 = 4, center = false); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 4, r2 = 4, center = false); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 0.5, r2 = 0.5, center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 1.5, r2 = 1.5, center = true); + } + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 2.5, r2 = 2.5, center = true); + } + } + } + group() { + multmatrix([[1, 0, 0, -15], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 6, 2], center = true); + } + multmatrix([[1, 0, 0, -13], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 6.8, 2], center = true); + } + multmatrix([[1, 0, 0, -11], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 7.6, 2], center = true); + } + multmatrix([[1, 0, 0, -9], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 8.4, 2], center = true); + } + multmatrix([[1, 0, 0, -7], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 9.2, 2], center = true); + } + } + group(); + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 4, r2 = 4, center = false); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } + group(); + group(); + group(); + group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); + } + } +} diff --git a/tests/regression/dumptest/for-tests-expected.txt b/tests/regression/dumptest/for-tests-expected.txt deleted file mode 100644 index f9cf5e0..0000000 --- a/tests/regression/dumptest/for-tests-expected.txt +++ /dev/null @@ -1,114 +0,0 @@ - group(); - group(); - multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group(); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); - } - } - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 4, r2 = 4, center = false); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 4, r2 = 4, center = false); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 0.5, r2 = 0.5, center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 1.5, r2 = 1.5, center = true); - } - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 2.5, r2 = 2.5, center = true); - } - } - } - group() { - multmatrix([[1, 0, 0, -15], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 6, 2], center = true); - } - multmatrix([[1, 0, 0, -13], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 6.8, 2], center = true); - } - multmatrix([[1, 0, 0, -11], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 7.6, 2], center = true); - } - multmatrix([[1, 0, 0, -9], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 8.4, 2], center = true); - } - multmatrix([[1, 0, 0, -7], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 9.2, 2], center = true); - } - } - group(); - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 4, r2 = 4, center = false); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - group(); - group(); - group(); - group() { - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = false); - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 5, r2 = 5, center = false); - } - } - diff --git a/tests/regression/dumptest/glide-expected.csg b/tests/regression/dumptest/glide-expected.csg new file mode 100644 index 0000000..67e40b8 --- /dev/null +++ b/tests/regression/dumptest/glide-expected.csg @@ -0,0 +1,3 @@ +group() { + glide(path = undef, convexity = 0); +} diff --git a/tests/regression/dumptest/glide-expected.txt b/tests/regression/dumptest/glide-expected.txt deleted file mode 100644 index 74fbc08..0000000 --- a/tests/regression/dumptest/glide-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - glide(path = undef, convexity = 0); - diff --git a/tests/regression/dumptest/group-expected.csg b/tests/regression/dumptest/group-expected.csg new file mode 100644 index 0000000..434cc8f --- /dev/null +++ b/tests/regression/dumptest/group-expected.csg @@ -0,0 +1,3 @@ +group() { + group(); +} diff --git a/tests/regression/dumptest/group-expected.txt b/tests/regression/dumptest/group-expected.txt deleted file mode 100644 index b2915cb..0000000 --- a/tests/regression/dumptest/group-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - group(); - diff --git a/tests/regression/dumptest/highlight-and-background-modifier-expected.csg b/tests/regression/dumptest/highlight-and-background-modifier-expected.csg new file mode 100644 index 0000000..8402355 --- /dev/null +++ b/tests/regression/dumptest/highlight-and-background-modifier-expected.csg @@ -0,0 +1,63 @@ +group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + %cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + %group() { + cube(size = [25, 6, 3], center = true); + } + } + %multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + color([0, 0.501961, 0, 1]) { + cube(size = [10, 4, 10], center = true); + } + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + } + %multmatrix([[1, 0, 0, 13], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + group() { + cube(size = [25, 6, 3], center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + color([0, 0.501961, 0, 1]) { + cube(size = [10, 4, 10], center = true); + } + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + } + } + multmatrix([[1, 0, 0, 26], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + group() { + cube(size = [25, 6, 3], center = true); + } + } + %multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + color([0, 0.501961, 0, 1]) { + cube(size = [10, 4, 10], center = true); + } + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + } + } +} diff --git a/tests/regression/dumptest/highlight-and-background-modifier-expected.txt b/tests/regression/dumptest/highlight-and-background-modifier-expected.txt deleted file mode 100644 index eb8931c..0000000 --- a/tests/regression/dumptest/highlight-and-background-modifier-expected.txt +++ /dev/null @@ -1,62 +0,0 @@ - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - %cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - %group() { - cube(size = [25, 6, 3], center = true); - } - } - %multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - color([0, 0.501961, 0, 1]) { - cube(size = [10, 4, 10], center = true); - } - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - } - %multmatrix([[1, 0, 0, 13], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - group() { - cube(size = [25, 6, 3], center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - color([0, 0.501961, 0, 1]) { - cube(size = [10, 4, 10], center = true); - } - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - } - } - multmatrix([[1, 0, 0, 26], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - group() { - cube(size = [25, 6, 3], center = true); - } - } - %multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - color([0, 0.501961, 0, 1]) { - cube(size = [10, 4, 10], center = true); - } - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - } - } - diff --git a/tests/regression/dumptest/highlight-modifier-expected.csg b/tests/regression/dumptest/highlight-modifier-expected.csg new file mode 100644 index 0000000..70f3d19 --- /dev/null +++ b/tests/regression/dumptest/highlight-modifier-expected.csg @@ -0,0 +1,21 @@ +group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + } + group() { + cube(size = [25, 6, 3], center = true); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + color([0, 0.501961, 0, 1]) { + cube(size = [10, 4, 10], center = true); + } + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + } +} diff --git a/tests/regression/dumptest/highlight-modifier-expected.txt b/tests/regression/dumptest/highlight-modifier-expected.txt deleted file mode 100644 index c0a29ad..0000000 --- a/tests/regression/dumptest/highlight-modifier-expected.txt +++ /dev/null @@ -1,20 +0,0 @@ - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - } - group() { - cube(size = [25, 6, 3], center = true); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - color([0, 0.501961, 0, 1]) { - cube(size = [10, 4, 10], center = true); - } - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - } - diff --git a/tests/regression/dumptest/hull-expected.csg b/tests/regression/dumptest/hull-expected.csg new file mode 100644 index 0000000..6f777b0 --- /dev/null +++ b/tests/regression/dumptest/hull-expected.csg @@ -0,0 +1,3 @@ +group() { + hull(); +} diff --git a/tests/regression/dumptest/hull-expected.txt b/tests/regression/dumptest/hull-expected.txt deleted file mode 100644 index 3f27d2f..0000000 --- a/tests/regression/dumptest/hull-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - hull(); - diff --git a/tests/regression/dumptest/hull-tests-expected.csg b/tests/regression/dumptest/hull-tests-expected.csg new file mode 100644 index 0000000..22b860c --- /dev/null +++ b/tests/regression/dumptest/hull-tests-expected.csg @@ -0,0 +1,47 @@ +group() { +group() { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 1, r = 10); + } + difference() { + circle($fn = 0, $fa = 12, $fs = 1, r = 10); + circle($fn = 0, $fa = 12, $fs = 1, r = 5); + } + } + } + multmatrix([[1, 0, 0, 40], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 1, r = 10); + } + circle($fn = 0, $fa = 12, $fs = 1, r = 10); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 10, r1 = 1, r2 = 1, center = false); + } + difference() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 10, r1 = 1, r2 = 1, center = false); + cylinder($fn = 0, $fa = 12, $fs = 1, h = 5, r1 = 1, r2 = 1, center = false); + } + } + } + } + multmatrix([[1, 0, 0, 40], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 1, r1 = 10, r2 = 10, center = false); + } + cylinder($fn = 0, $fa = 12, $fs = 1, h = 1, r1 = 10, r2 = 10, center = false); + } + } + } +}} diff --git a/tests/regression/dumptest/hull-tests-expected.txt b/tests/regression/dumptest/hull-tests-expected.txt deleted file mode 100644 index fd204b6..0000000 --- a/tests/regression/dumptest/hull-tests-expected.txt +++ /dev/null @@ -1,46 +0,0 @@ -group() { - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 1, r = 10); - } - difference() { - circle($fn = 0, $fa = 12, $fs = 1, r = 10); - circle($fn = 0, $fa = 12, $fs = 1, r = 5); - } - } - } - multmatrix([[1, 0, 0, 40], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 1, r = 10); - } - circle($fn = 0, $fa = 12, $fs = 1, r = 10); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 10, r1 = 1, r2 = 1, center = false); - } - difference() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 10, r1 = 1, r2 = 1, center = false); - cylinder($fn = 0, $fa = 12, $fs = 1, h = 5, r1 = 1, r2 = 1, center = false); - } - } - } - } - multmatrix([[1, 0, 0, 40], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 1, r1 = 10, r2 = 10, center = false); - } - cylinder($fn = 0, $fa = 12, $fs = 1, h = 1, r1 = 10, r2 = 10, center = false); - } - } - } -} diff --git a/tests/regression/dumptest/hull2-tests-expected.csg b/tests/regression/dumptest/hull2-tests-expected.csg new file mode 100644 index 0000000..4d4f207 --- /dev/null +++ b/tests/regression/dumptest/hull2-tests-expected.csg @@ -0,0 +1,66 @@ +group() { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + } + difference() { + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + circle($fn = 0, $fa = 12, $fs = 2, r = 5); + } + } + } + multmatrix([[1, 0, 0, 40], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + } + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + hull() { + multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [2, 2], center = false); + } + multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [2, 2], center = false); + } + square(size = [2, 2], center = false); + } + } + } + multmatrix([[1, 0, 0, 30], [0, 1, 0, -25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + hull() { + group() { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + group() { + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 3); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + } + } + } + group() { + hull() { + square(size = [0, 0], center = false); + circle($fn = 0, $fa = 12, $fs = 2, r = 0); + } + } +} diff --git a/tests/regression/dumptest/hull2-tests-expected.txt b/tests/regression/dumptest/hull2-tests-expected.txt deleted file mode 100644 index c14282f..0000000 --- a/tests/regression/dumptest/hull2-tests-expected.txt +++ /dev/null @@ -1,65 +0,0 @@ - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - } - difference() { - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - circle($fn = 0, $fa = 12, $fs = 2, r = 5); - } - } - } - multmatrix([[1, 0, 0, 40], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - } - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - hull() { - multmatrix([[1, 0, 0, 15], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [2, 2], center = false); - } - multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [2, 2], center = false); - } - square(size = [2, 2], center = false); - } - } - } - multmatrix([[1, 0, 0, 30], [0, 1, 0, -25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - hull() { - group() { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - group() { - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 3); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - } - } - } - group() { - hull() { - square(size = [0, 0], center = false); - circle($fn = 0, $fa = 12, $fs = 2, r = 0); - } - } - diff --git a/tests/regression/dumptest/hull3-tests-expected.csg b/tests/regression/dumptest/hull3-tests-expected.csg new file mode 100644 index 0000000..a15f0ce --- /dev/null +++ b/tests/regression/dumptest/hull3-tests-expected.csg @@ -0,0 +1,37 @@ +group() { + hull(); + hull(); + hull() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 10, r2 = 10, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [5, 5, 5], center = true); + } + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + hull() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); + } + difference() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 10, r2 = 10, center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 5, center = true); + } + } + } + multmatrix([[1, 0, 0, -5], [0, 1, 0, -5], [0, 0, 1, -5], [0, 0, 0, 1]]) { + hull() { + intersection() { + cube(size = [1, 1, 1], center = false); + multmatrix([[1, 0, 0, -1], [0, 1, 0, -1], [0, 0, 1, -1], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + } + } + } + } + group() { + hull() { + cube(size = [0, 0, 0], center = false); + sphere($fn = 0, $fa = 12, $fs = 2, r = 0); + } + } +} diff --git a/tests/regression/dumptest/hull3-tests-expected.txt b/tests/regression/dumptest/hull3-tests-expected.txt deleted file mode 100644 index f8def3b..0000000 --- a/tests/regression/dumptest/hull3-tests-expected.txt +++ /dev/null @@ -1,36 +0,0 @@ - hull(); - hull(); - hull() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 10, r2 = 10, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [5, 5, 5], center = true); - } - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - hull() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 3, r2 = 3, center = false); - } - difference() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 10, r2 = 10, center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 5, center = true); - } - } - } - multmatrix([[1, 0, 0, -5], [0, 1, 0, -5], [0, 0, 1, -5], [0, 0, 0, 1]]) { - hull() { - intersection() { - cube(size = [1, 1, 1], center = false); - multmatrix([[1, 0, 0, -1], [0, 1, 0, -1], [0, 0, 1, -1], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - } - } - } - } - group() { - hull() { - cube(size = [0, 0, 0], center = false); - sphere($fn = 0, $fa = 12, $fs = 2, r = 0); - } - } - diff --git a/tests/regression/dumptest/if-expected.csg b/tests/regression/dumptest/if-expected.csg new file mode 100644 index 0000000..434cc8f --- /dev/null +++ b/tests/regression/dumptest/if-expected.csg @@ -0,0 +1,3 @@ +group() { + group(); +} diff --git a/tests/regression/dumptest/if-expected.txt b/tests/regression/dumptest/if-expected.txt deleted file mode 100644 index b2915cb..0000000 --- a/tests/regression/dumptest/if-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - group(); - diff --git a/tests/regression/dumptest/ifelse-tests-expected.csg b/tests/regression/dumptest/ifelse-tests-expected.csg new file mode 100644 index 0000000..e5b5c6a --- /dev/null +++ b/tests/regression/dumptest/ifelse-tests-expected.csg @@ -0,0 +1,62 @@ +group() { + group() { + cube(size = [2, 2, 2], center = true); + multmatrix([[1, 0, 0, -3], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + cube(size = [2, 2, 2], center = true); + } + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + cube(size = [2, 2, 2], center = true); + } + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } + multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [2, 2, 2], center = true); + } + } +} diff --git a/tests/regression/dumptest/ifelse-tests-expected.txt b/tests/regression/dumptest/ifelse-tests-expected.txt deleted file mode 100644 index e2d3fce..0000000 --- a/tests/regression/dumptest/ifelse-tests-expected.txt +++ /dev/null @@ -1,61 +0,0 @@ - group() { - cube(size = [2, 2, 2], center = true); - multmatrix([[1, 0, 0, -3], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - cube(size = [2, 2, 2], center = true); - } - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - cube(size = [2, 2, 2], center = true); - } - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - multmatrix([[1, 0, 0, 15], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [2, 2, 2], center = true); - } - } - diff --git a/tests/regression/dumptest/import-expected.csg b/tests/regression/dumptest/import-expected.csg new file mode 100644 index 0000000..3cafd32 --- /dev/null +++ b/tests/regression/dumptest/import-expected.csg @@ -0,0 +1,3 @@ +group() { + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/import-expected.txt b/tests/regression/dumptest/import-expected.txt deleted file mode 100644 index b1d81de..0000000 --- a/tests/regression/dumptest/import-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/import_dxf-expected.csg b/tests/regression/dumptest/import_dxf-expected.csg new file mode 100644 index 0000000..3cafd32 --- /dev/null +++ b/tests/regression/dumptest/import_dxf-expected.csg @@ -0,0 +1,3 @@ +group() { + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/import_dxf-expected.txt b/tests/regression/dumptest/import_dxf-expected.txt deleted file mode 100644 index b1d81de..0000000 --- a/tests/regression/dumptest/import_dxf-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/import_dxf-tests-expected.csg b/tests/regression/dumptest/import_dxf-tests-expected.csg new file mode 100644 index 0000000..b6c6d0c --- /dev/null +++ b/tests/regression/dumptest/import_dxf-tests-expected.csg @@ -0,0 +1,28 @@ +group() { + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + multmatrix([[1, 0, 0, -210], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/polygons.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, -210], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/polygons.dxf", layer = "", origin = [0, 110], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, -210], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/polygons.dxf", layer = "", origin = [110, 110], scale = 0.5, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + import(file = "../../dxf/multiple-layers.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + multmatrix([[1, 0, 0, -200], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/multiple-layers.dxf", layer = "0", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/multiple-layers.dxf", layer = "0", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 200], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/multiple-layers.dxf", layer = "noname", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/multiple-layers.dxf", layer = "Layer with a pretty long name including \\ \"special\" /'\\\\ characters", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 200], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "../../dxf/polygons.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } +} diff --git a/tests/regression/dumptest/import_dxf-tests-expected.txt b/tests/regression/dumptest/import_dxf-tests-expected.txt deleted file mode 100644 index d98b3e2..0000000 --- a/tests/regression/dumptest/import_dxf-tests-expected.txt +++ /dev/null @@ -1,27 +0,0 @@ - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - multmatrix([[1, 0, 0, -210], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/polygons.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, -210], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/polygons.dxf", layer = "", origin = [0, 110], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, -210], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/polygons.dxf", layer = "", origin = [110, 110], scale = 0.5, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - import(file = "../../dxf/multiple-layers.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - multmatrix([[1, 0, 0, -200], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/multiple-layers.dxf", layer = "0", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/multiple-layers.dxf", layer = "0", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 200], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/multiple-layers.dxf", layer = "noname", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 200], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/multiple-layers.dxf", layer = "Layer with a pretty long name including \\ \"special\" /'\\\\ characters", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 200], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "../../dxf/polygons.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - diff --git a/tests/regression/dumptest/import_off-expected.csg b/tests/regression/dumptest/import_off-expected.csg new file mode 100644 index 0000000..3cafd32 --- /dev/null +++ b/tests/regression/dumptest/import_off-expected.csg @@ -0,0 +1,3 @@ +group() { + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/import_off-expected.txt b/tests/regression/dumptest/import_off-expected.txt deleted file mode 100644 index b1d81de..0000000 --- a/tests/regression/dumptest/import_off-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/import_stl-expected.csg b/tests/regression/dumptest/import_stl-expected.csg new file mode 100644 index 0000000..3cafd32 --- /dev/null +++ b/tests/regression/dumptest/import_stl-expected.csg @@ -0,0 +1,3 @@ +group() { + import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/import_stl-expected.txt b/tests/regression/dumptest/import_stl-expected.txt deleted file mode 100644 index b1d81de..0000000 --- a/tests/regression/dumptest/import_stl-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - import(file = "", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/import_stl-tests-expected.csg b/tests/regression/dumptest/import_stl-tests-expected.csg new file mode 100644 index 0000000..a7f460e --- /dev/null +++ b/tests/regression/dumptest/import_stl-tests-expected.csg @@ -0,0 +1,15 @@ +group() { + import(file = "import.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "import.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "import_bin.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "import_bin_solid.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + import(file = "import.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } +} diff --git a/tests/regression/dumptest/import_stl-tests-expected.txt b/tests/regression/dumptest/import_stl-tests-expected.txt deleted file mode 100644 index 0d46a6f..0000000 --- a/tests/regression/dumptest/import_stl-tests-expected.txt +++ /dev/null @@ -1,14 +0,0 @@ - import(file = "import.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "import.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "import_bin.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "import_bin_solid.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - import(file = "import.stl", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - diff --git a/tests/regression/dumptest/include-tests-expected.csg b/tests/regression/dumptest/include-tests-expected.csg new file mode 100644 index 0000000..37e3952 --- /dev/null +++ b/tests/regression/dumptest/include-tests-expected.csg @@ -0,0 +1,83 @@ +group() { + group() { + group() { + cube(size = [1, 1, 1], center = true); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0.7, r2 = 0.2, center = true); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 10, $fa = 12, $fs = 2, h = 1, r1 = 0.5, r2 = 0.5, center = true); + } + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cube(size = [1, 1, 1], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 0.4, r2 = 0.4, center = true); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [0.5, 0.5, 1], center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 16, $fa = 12, $fs = 2, r = 0.7); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1.5708, 0.5, 0.5], center = true); + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1.43239, 0.5, 0.5], center = true); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, -4], [0, 0, 1, -0.5], [0, 0, 0, 1]]) { + multmatrix([[0.05, 0, 0, 0], [0, 0.05, 0, 0], [0, 0, 0.05, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 17], [0, 0, 0, 1]]) { + cylinder($fn = 30, $fa = 12, $fs = 2, h = 8, r1 = 6, r2 = 6, center = false); + cylinder($fn = 20, $fa = 12, $fs = 2, h = 10.5, r1 = 2.5, r2 = 2.5, center = false); + } + multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [12, 22.8, 19.5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 17], [0, 0, 0, 1]]) { + cube(size = [12, 7, 2.5], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 20.8], [0, 0, 1, 17], [0, 0, 0, 1]]) { + cube(size = [12, 7, 2.5], center = false); + } + } + group(); + multmatrix([[1, 0, 0, -6], [0, 1, 0, 0], [0, 0, 1, 19], [0, 0, 0, 1]]) { + multmatrix([[0, 0, 1, 0], [1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) { + group() { + linear_extrude(height = 12, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + polygon(points = [[0, 0], [18, 0], [0, 4]], paths = [[0, 1, 2]], convexity = 1); + } + } + } + } + multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 19], [0, 0, 0, 1]]) { + cube(size = [12, 6.5, 4], center = false); + } + } + group(); + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/include-tests-expected.txt b/tests/regression/dumptest/include-tests-expected.txt deleted file mode 100644 index 3f3ecd9..0000000 --- a/tests/regression/dumptest/include-tests-expected.txt +++ /dev/null @@ -1,82 +0,0 @@ - group() { - group() { - cube(size = [1, 1, 1], center = true); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0.7, r2 = 0.2, center = true); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 10, $fa = 12, $fs = 2, h = 1, r1 = 0.5, r2 = 0.5, center = true); - } - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cube(size = [1, 1, 1], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 0.4, r2 = 0.4, center = true); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [0.5, 0.5, 1], center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 16, $fa = 12, $fs = 2, r = 0.7); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1.5708, 0.5, 0.5], center = true); - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1.43239, 0.5, 0.5], center = true); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, -4], [0, 0, 1, -0.5], [0, 0, 0, 1]]) { - multmatrix([[0.05, 0, 0, 0], [0, 0.05, 0, 0], [0, 0, 0.05, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 17], [0, 0, 0, 1]]) { - cylinder($fn = 30, $fa = 12, $fs = 2, h = 8, r1 = 6, r2 = 6, center = false); - cylinder($fn = 20, $fa = 12, $fs = 2, h = 10.5, r1 = 2.5, r2 = 2.5, center = false); - } - multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [12, 22.8, 19.5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 17], [0, 0, 0, 1]]) { - cube(size = [12, 7, 2.5], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 20.8], [0, 0, 1, 17], [0, 0, 0, 1]]) { - cube(size = [12, 7, 2.5], center = false); - } - } - group(); - multmatrix([[1, 0, 0, -6], [0, 1, 0, 0], [0, 0, 1, 19], [0, 0, 0, 1]]) { - multmatrix([[0, 0, 1, 0], [1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) { - group() { - linear_extrude(height = 12, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - polygon(points = [[0, 0], [18, 0], [0, 4]], paths = [[0, 1, 2]], convexity = 1); - } - } - } - } - multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 19], [0, 0, 0, 1]]) { - cube(size = [12, 6.5, 4], center = false); - } - } - group(); - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/intersection-expected.csg b/tests/regression/dumptest/intersection-expected.csg new file mode 100644 index 0000000..409e196 --- /dev/null +++ b/tests/regression/dumptest/intersection-expected.csg @@ -0,0 +1,3 @@ +group() { + intersection(); +} diff --git a/tests/regression/dumptest/intersection-expected.txt b/tests/regression/dumptest/intersection-expected.txt deleted file mode 100644 index ed3847d..0000000 --- a/tests/regression/dumptest/intersection-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - intersection(); - diff --git a/tests/regression/dumptest/intersection-tests-expected.csg b/tests/regression/dumptest/intersection-tests-expected.csg new file mode 100644 index 0000000..2b542ef --- /dev/null +++ b/tests/regression/dumptest/intersection-tests-expected.csg @@ -0,0 +1,57 @@ +group() { + intersection(); + intersection(); + intersection() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 3], [0, 0, 0, 1]]) { + cube(size = [4, 4, 6], center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + cube(size = [10, 10, 10], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 12, r1 = 4, r2 = 4, center = true); + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + cube(size = [10, 10, 10], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 12, r1 = 4, r2 = 4, center = true); + multmatrix([[2.22045e-16, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 2.22045e-16, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 12, r1 = 4, r2 = 4, center = true); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + cube(size = [10, 10, 10], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.01], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); + } + } + } + multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + cube(size = [10, 10, 10], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 6.99], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); + } + } + } + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + cube(size = [10, 10, 10], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -10], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [10, 10, 10], center = true); + } + } + } + multmatrix([[1, 0, 0, -12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + intersection() { + cube(size = [10, 10, 10], center = true); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -9.99], [0, 0, 1, -9.99], [0, 0, 0, 1]]) { + cube(size = [10, 10, 10], center = true); + } + } + } +} diff --git a/tests/regression/dumptest/intersection-tests-expected.txt b/tests/regression/dumptest/intersection-tests-expected.txt deleted file mode 100644 index a9dba29..0000000 --- a/tests/regression/dumptest/intersection-tests-expected.txt +++ /dev/null @@ -1,56 +0,0 @@ - intersection(); - intersection(); - intersection() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 3], [0, 0, 0, 1]]) { - cube(size = [4, 4, 6], center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - cube(size = [10, 10, 10], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 12, r1 = 4, r2 = 4, center = true); - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - cube(size = [10, 10, 10], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 12, r1 = 4, r2 = 4, center = true); - multmatrix([[2.22045e-16, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 2.22045e-16, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 12, r1 = 4, r2 = 4, center = true); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - cube(size = [10, 10, 10], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7.01], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); - } - } - } - multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - cube(size = [10, 10, 10], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 6.99], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 4, r1 = 4, r2 = 4, center = true); - } - } - } - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - cube(size = [10, 10, 10], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -10], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [10, 10, 10], center = true); - } - } - } - multmatrix([[1, 0, 0, -12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - intersection() { - cube(size = [10, 10, 10], center = true); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -9.99], [0, 0, 1, -9.99], [0, 0, 0, 1]]) { - cube(size = [10, 10, 10], center = true); - } - } - } - diff --git a/tests/regression/dumptest/intersection_for-expected.csg b/tests/regression/dumptest/intersection_for-expected.csg new file mode 100644 index 0000000..409e196 --- /dev/null +++ b/tests/regression/dumptest/intersection_for-expected.csg @@ -0,0 +1,3 @@ +group() { + intersection(); +} diff --git a/tests/regression/dumptest/intersection_for-expected.txt b/tests/regression/dumptest/intersection_for-expected.txt deleted file mode 100644 index ed3847d..0000000 --- a/tests/regression/dumptest/intersection_for-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - intersection(); - diff --git a/tests/regression/dumptest/intersection_for-tests-expected.csg b/tests/regression/dumptest/intersection_for-tests-expected.csg new file mode 100644 index 0000000..68e8321 --- /dev/null +++ b/tests/regression/dumptest/intersection_for-tests-expected.csg @@ -0,0 +1,18 @@ +group() { + intersection(); + intersection(); + intersection() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + multmatrix([[0.46984631039, 0.88256411925, 0.01802831123, 0], [-0.81379768134, 0.44096961053, -0.37852230637, 0], [-0.34202014332, 0.16317591116, 0.92541657839, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + multmatrix([[0.41721770627, 0.66835566162, -0.61581660836, 0], [0.64245892818, -0.69617191219, -0.32029860173, 0], [-0.64278760968, -0.26200263022, -0.71984631039, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + multmatrix([[0.0190076282, -0.60192849838, 0.7983237394, 0], [0.02926918072, 0.79846077351, 0.60133493846, 0], [-0.99939082701, 0.01193633086, 0.03279479952, 0], [0, 0, 0, 1]]) { + cube(size = [100, 20, 20], center = true); + } + } +} diff --git a/tests/regression/dumptest/intersection_for-tests-expected.txt b/tests/regression/dumptest/intersection_for-tests-expected.txt deleted file mode 100644 index 8f500c9..0000000 --- a/tests/regression/dumptest/intersection_for-tests-expected.txt +++ /dev/null @@ -1,17 +0,0 @@ - intersection(); - intersection(); - intersection() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - multmatrix([[0.46984631039, 0.88256411925, 0.01802831123, 0], [-0.81379768134, 0.44096961053, -0.37852230637, 0], [-0.34202014332, 0.16317591116, 0.92541657839, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - multmatrix([[0.41721770627, 0.66835566162, -0.61581660836, 0], [0.64245892818, -0.69617191219, -0.32029860173, 0], [-0.64278760968, -0.26200263022, -0.71984631039, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - multmatrix([[0.0190076282, -0.60192849838, 0.7983237394, 0], [0.02926918072, 0.79846077351, 0.60133493846, 0], [-0.99939082701, 0.01193633086, 0.03279479952, 0], [0, 0, 0, 1]]) { - cube(size = [100, 20, 20], center = true); - } - } - diff --git a/tests/regression/dumptest/linear_extrude-expected.csg b/tests/regression/dumptest/linear_extrude-expected.csg new file mode 100644 index 0000000..5404abf --- /dev/null +++ b/tests/regression/dumptest/linear_extrude-expected.csg @@ -0,0 +1,3 @@ +group() { + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/linear_extrude-expected.txt b/tests/regression/dumptest/linear_extrude-expected.txt deleted file mode 100644 index 9ad9e00..0000000 --- a/tests/regression/dumptest/linear_extrude-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/linear_extrude-scale-zero-tests-expected.csg b/tests/regression/dumptest/linear_extrude-scale-zero-tests-expected.csg new file mode 100644 index 0000000..e4d2430 --- /dev/null +++ b/tests/regression/dumptest/linear_extrude-scale-zero-tests-expected.csg @@ -0,0 +1,254 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + difference() { + square(size = [2, 2], center = true); + multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/linear_extrude-scale-zero-tests-expected.txt b/tests/regression/dumptest/linear_extrude-scale-zero-tests-expected.txt deleted file mode 100644 index 950c724..0000000 --- a/tests/regression/dumptest/linear_extrude-scale-zero-tests-expected.txt +++ /dev/null @@ -1,253 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 0, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 1], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [1, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, -1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 3, center = false, convexity = 1, twist = 180, slices = 20, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - difference() { - square(size = [2, 2], center = true); - multmatrix([[1, 0, 0, -0.5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/linear_extrude-tests-expected.csg b/tests/regression/dumptest/linear_extrude-tests-expected.csg new file mode 100644 index 0000000..a0deb81 --- /dev/null +++ b/tests/regression/dumptest/linear_extrude-tests-expected.csg @@ -0,0 +1,63 @@ +group() { + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { + cube(size = [1, 1, 1], center = false); + } + linear_extrude(height = 10, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = false); + } + multmatrix([[1, 0, 0, 19], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 10, center = true, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + difference() { + circle($fn = 0, $fa = 12, $fs = 2, r = 5); + circle($fn = 0, $fa = 12, $fs = 2, r = 3); + } + } + } + multmatrix([[1, 0, 0, 31.5], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 10, center = false, convexity = 1, twist = -45, slices = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + polygon(points = [[-5, -2.5], [5, -2.5], [0, 2.5]], paths = undef, convexity = 1); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 20, center = false, convexity = 1, twist = 45, slices = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = false); + } + } + multmatrix([[1, 0, 0, 19], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 20, center = false, convexity = 1, twist = 45, slices = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 5, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = false); + } + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 10, center = false, convexity = 1, scale = [2, 2], $fn = 0, $fa = 12, $fs = 2) { + square(size = [5, 5], center = true); + } + } + multmatrix([[1, 0, 0, -15], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = false); + } + } + multmatrix([[1, 0, 0, -10], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 15, center = false, convexity = 1, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = true); + } + } + multmatrix([[1, 0, 0, -15], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 10, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 0, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + square(size = [10, 10], center = true); + } + } +} diff --git a/tests/regression/dumptest/linear_extrude-tests-expected.txt b/tests/regression/dumptest/linear_extrude-tests-expected.txt deleted file mode 100644 index face5e2..0000000 --- a/tests/regression/dumptest/linear_extrude-tests-expected.txt +++ /dev/null @@ -1,62 +0,0 @@ - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { - cube(size = [1, 1, 1], center = false); - } - linear_extrude(height = 10, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = false); - } - multmatrix([[1, 0, 0, 19], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 10, center = true, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - difference() { - circle($fn = 0, $fa = 12, $fs = 2, r = 5); - circle($fn = 0, $fa = 12, $fs = 2, r = 3); - } - } - } - multmatrix([[1, 0, 0, 31.5], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 10, center = false, convexity = 1, twist = -45, slices = 3, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - polygon(points = [[-5, -2.5], [5, -2.5], [0, 2.5]], paths = undef, convexity = 1); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 20, center = false, convexity = 1, twist = 45, slices = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = false); - } - } - multmatrix([[1, 0, 0, 19], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 20, center = false, convexity = 1, twist = 45, slices = 10, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 5, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = false); - } - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 10, center = false, convexity = 1, scale = [2, 2], $fn = 0, $fa = 12, $fs = 2) { - square(size = [5, 5], center = true); - } - } - multmatrix([[1, 0, 0, -15], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = false); - } - } - multmatrix([[1, 0, 0, -10], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 15, center = false, convexity = 1, scale = [0, 0], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = true); - } - } - multmatrix([[1, 0, 0, -15], [0, 1, 0, -15], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 10, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 0, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - square(size = [10, 10], center = true); - } - } - diff --git a/tests/regression/dumptest/localfiles-compatibility-test-expected.csg b/tests/regression/dumptest/localfiles-compatibility-test-expected.csg new file mode 100644 index 0000000..f6a574e --- /dev/null +++ b/tests/regression/dumptest/localfiles-compatibility-test-expected.csg @@ -0,0 +1,21 @@ +group() { + group() { + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + import(file = "localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, -250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(file = "localfile.dxf", layer = "", origin = [0, 0], height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 350], [0, 0, 1, 0], [0, 0, 0, 1]]) { + rotate_extrude(file = "localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[200, 0, 0, 0], [0, 200, 0, 0], [0, 0, 50, 0], [0, 0, 0, 1]]) { + surface(file = "localfile.dat", center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -200], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 100); + } + } +} diff --git a/tests/regression/dumptest/localfiles-compatibility-test-expected.txt b/tests/regression/dumptest/localfiles-compatibility-test-expected.txt deleted file mode 100644 index 95ba49b..0000000 --- a/tests/regression/dumptest/localfiles-compatibility-test-expected.txt +++ /dev/null @@ -1,20 +0,0 @@ - group() { - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - import(file = "localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, -250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(file = "localfile.dxf", layer = "", origin = [0, 0], height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 350], [0, 0, 1, 0], [0, 0, 0, 1]]) { - rotate_extrude(file = "localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[200, 0, 0, 0], [0, 200, 0, 0], [0, 0, 50, 0], [0, 0, 0, 1]]) { - surface(file = "localfile.dat", center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -200], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 100); - } - } - diff --git a/tests/regression/dumptest/localfiles-test-expected.csg b/tests/regression/dumptest/localfiles-test-expected.csg new file mode 100644 index 0000000..5bb64f3 --- /dev/null +++ b/tests/regression/dumptest/localfiles-test-expected.csg @@ -0,0 +1,21 @@ +group() { + group() { + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + import(file = "localfiles_dir/localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, -250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(file = "localfiles_dir/localfile.dxf", layer = "", origin = [0, 0], height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 350], [0, 0, 1, 0], [0, 0, 0, 1]]) { + rotate_extrude(file = "localfiles_dir/localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); + } + multmatrix([[1, 0, 0, 250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[200, 0, 0, 0], [0, 200, 0, 0], [0, 0, 50, 0], [0, 0, 0, 1]]) { + surface(file = "localfiles_dir/localfile.dat", center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -200], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 100); + } + } +} diff --git a/tests/regression/dumptest/localfiles-test-expected.txt b/tests/regression/dumptest/localfiles-test-expected.txt deleted file mode 100644 index a7e81e5..0000000 --- a/tests/regression/dumptest/localfiles-test-expected.txt +++ /dev/null @@ -1,20 +0,0 @@ - group() { - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - import(file = "localfiles_dir/localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, -250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(file = "localfiles_dir/localfile.dxf", layer = "", origin = [0, 0], height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 350], [0, 0, 1, 0], [0, 0, 0, 1]]) { - rotate_extrude(file = "localfiles_dir/localfile.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - } - multmatrix([[1, 0, 0, 250], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[200, 0, 0, 0], [0, 200, 0, 0], [0, 0, 50, 0], [0, 0, 0, 1]]) { - surface(file = "localfiles_dir/localfile.dat", center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -200], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 100); - } - } - diff --git a/tests/regression/dumptest/minkowski-expected.csg b/tests/regression/dumptest/minkowski-expected.csg new file mode 100644 index 0000000..ecab5f3 --- /dev/null +++ b/tests/regression/dumptest/minkowski-expected.csg @@ -0,0 +1,3 @@ +group() { + minkowski(convexity = 0); +} diff --git a/tests/regression/dumptest/minkowski-expected.txt b/tests/regression/dumptest/minkowski-expected.txt deleted file mode 100644 index 799062f..0000000 --- a/tests/regression/dumptest/minkowski-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - minkowski(convexity = 0); - diff --git a/tests/regression/dumptest/minkowski-tests-expected.csg b/tests/regression/dumptest/minkowski-tests-expected.csg new file mode 100644 index 0000000..1d132a9 --- /dev/null +++ b/tests/regression/dumptest/minkowski-tests-expected.csg @@ -0,0 +1,67 @@ +group() { +group() { + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + square(size = [10, 10], center = false); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [6, 6], center = false); + } + } + circle($fn = 0, $fa = 12, $fs = 1, r = 2); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + square(size = [10, 10], center = false); + square(size = [5, 5], center = false); + } + circle($fn = 0, $fa = 12, $fs = 1, r = 5); + } + } + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + square(size = [10, 10], center = false); + circle($fn = 0, $fa = 12, $fs = 1, r = 5); + } + } + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + cube(size = [10, 10, 5], center = false); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, -2], [0, 0, 0, 1]]) { + cube(size = [6, 6, 10], center = false); + } + } + cylinder($fn = 0, $fa = 12, $fs = 1, h = 1, r1 = 2, r2 = 2, center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + cube(size = [10, 10, 5], center = false); + cube(size = [5, 5, 5], center = false); + } + cylinder($fn = 0, $fa = 12, $fs = 1, h = 5, r1 = 5, r2 = 5, center = false); + } + } + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + cube(size = [10, 10, 5], center = false); + cylinder($fn = 0, $fa = 12, $fs = 1, h = 5, r1 = 5, r2 = 5, center = false); + } + } + } +}} diff --git a/tests/regression/dumptest/minkowski-tests-expected.txt b/tests/regression/dumptest/minkowski-tests-expected.txt deleted file mode 100644 index 7435769..0000000 --- a/tests/regression/dumptest/minkowski-tests-expected.txt +++ /dev/null @@ -1,66 +0,0 @@ -group() { - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - square(size = [10, 10], center = false); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [6, 6], center = false); - } - } - circle($fn = 0, $fa = 12, $fs = 1, r = 2); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - square(size = [10, 10], center = false); - square(size = [5, 5], center = false); - } - circle($fn = 0, $fa = 12, $fs = 1, r = 5); - } - } - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - square(size = [10, 10], center = false); - circle($fn = 0, $fa = 12, $fs = 1, r = 5); - } - } - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - cube(size = [10, 10, 5], center = false); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, -2], [0, 0, 0, 1]]) { - cube(size = [6, 6, 10], center = false); - } - } - cylinder($fn = 0, $fa = 12, $fs = 1, h = 1, r1 = 2, r2 = 2, center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - cube(size = [10, 10, 5], center = false); - cube(size = [5, 5, 5], center = false); - } - cylinder($fn = 0, $fa = 12, $fs = 1, h = 5, r1 = 5, r2 = 5, center = false); - } - } - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - cube(size = [10, 10, 5], center = false); - cylinder($fn = 0, $fa = 12, $fs = 1, h = 5, r1 = 5, r2 = 5, center = false); - } - } - } -} diff --git a/tests/regression/dumptest/minkowski2-tests-expected.csg b/tests/regression/dumptest/minkowski2-tests-expected.csg new file mode 100644 index 0000000..ec67feb --- /dev/null +++ b/tests/regression/dumptest/minkowski2-tests-expected.csg @@ -0,0 +1,32 @@ +group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + square(size = [10, 10], center = true); + square(size = [8, 8], center = true); + } + circle($fn = 0, $fa = 12, $fs = 2, r = 2); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + square(size = [10, 10], center = false); + square(size = [5, 5], center = false); + } + circle($fn = 0, $fa = 12, $fs = 2, r = 5); + } + } + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + square(size = [10, 10], center = false); + circle($fn = 0, $fa = 12, $fs = 2, r = 5); + } + } + } +} diff --git a/tests/regression/dumptest/minkowski2-tests-expected.txt b/tests/regression/dumptest/minkowski2-tests-expected.txt deleted file mode 100644 index dc3ad86..0000000 --- a/tests/regression/dumptest/minkowski2-tests-expected.txt +++ /dev/null @@ -1,31 +0,0 @@ - multmatrix([[1, 0, 0, -20], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - square(size = [10, 10], center = true); - square(size = [8, 8], center = true); - } - circle($fn = 0, $fa = 12, $fs = 2, r = 2); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - square(size = [10, 10], center = false); - square(size = [5, 5], center = false); - } - circle($fn = 0, $fa = 12, $fs = 2, r = 5); - } - } - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - square(size = [10, 10], center = false); - circle($fn = 0, $fa = 12, $fs = 2, r = 5); - } - } - } - diff --git a/tests/regression/dumptest/minkowski3-tests-expected.csg b/tests/regression/dumptest/minkowski3-tests-expected.csg new file mode 100644 index 0000000..7dc82e1 --- /dev/null +++ b/tests/regression/dumptest/minkowski3-tests-expected.csg @@ -0,0 +1,34 @@ +group() { + multmatrix([[1, 0, 0, -20], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + cube(size = [10, 10, 5], center = true); + cube(size = [8, 8, 10], center = true); + } + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + difference() { + cube(size = [10, 10, 5], center = false); + cube(size = [5, 5, 5], center = false); + } + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 5, center = false); + } + } + } + multmatrix([[1, 0, 0, 25], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + minkowski(convexity = 0) { + cube(size = [10, 10, 5], center = false); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 5, center = false); + } + } + } + minkowski(convexity = 0); + minkowski(convexity = 0); +} diff --git a/tests/regression/dumptest/minkowski3-tests-expected.txt b/tests/regression/dumptest/minkowski3-tests-expected.txt deleted file mode 100644 index 5244014..0000000 --- a/tests/regression/dumptest/minkowski3-tests-expected.txt +++ /dev/null @@ -1,33 +0,0 @@ - multmatrix([[1, 0, 0, -20], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - cube(size = [10, 10, 5], center = true); - cube(size = [8, 8, 10], center = true); - } - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 2, r2 = 2, center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - difference() { - cube(size = [10, 10, 5], center = false); - cube(size = [5, 5, 5], center = false); - } - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 5, center = false); - } - } - } - multmatrix([[1, 0, 0, 25], [0, 1, 0, 25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - minkowski(convexity = 0) { - cube(size = [10, 10, 5], center = false); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 5, r1 = 5, r2 = 5, center = false); - } - } - } - minkowski(convexity = 0); - minkowski(convexity = 0); - diff --git a/tests/regression/dumptest/mirror-expected.csg b/tests/regression/dumptest/mirror-expected.csg new file mode 100644 index 0000000..3ad73cb --- /dev/null +++ b/tests/regression/dumptest/mirror-expected.csg @@ -0,0 +1,3 @@ +group() { + multmatrix([[-1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); +} diff --git a/tests/regression/dumptest/mirror-expected.txt b/tests/regression/dumptest/mirror-expected.txt deleted file mode 100644 index fdf0ee0..0000000 --- a/tests/regression/dumptest/mirror-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - multmatrix([[-1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - diff --git a/tests/regression/dumptest/module-recursion-expected.csg b/tests/regression/dumptest/module-recursion-expected.csg new file mode 100644 index 0000000..5117f53 --- /dev/null +++ b/tests/regression/dumptest/module-recursion-expected.csg @@ -0,0 +1,245 @@ +group() { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0.2, r2 = 0.2, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.7, r1 = 0.14, r2 = 0.14, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.7], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.7, r1 = 0.14, r2 = 0.14, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.7], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { + group() { + multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { + group() { + group(); + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/module-recursion-expected.txt b/tests/regression/dumptest/module-recursion-expected.txt deleted file mode 100644 index 9ad8877..0000000 --- a/tests/regression/dumptest/module-recursion-expected.txt +++ /dev/null @@ -1,244 +0,0 @@ - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0.2, r2 = 0.2, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 1], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.7, r1 = 0.14, r2 = 0.14, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.7], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.7, r1 = 0.14, r2 = 0.14, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.7], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.49, r1 = 0.098, r2 = 0.098, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.49], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 0.343, r1 = 0.0686, r2 = 0.0686, center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.343], [0, 0, 0, 1]]) { - group() { - multmatrix([[-1, 0, 0, 0], [0, -0.76604444311, 0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - multmatrix([[1, 0, 0, 0], [0, 0.76604444311, -0.64278760968, 0], [0, 0.64278760968, 0.76604444311, 0], [0, 0, 0, 1]]) { - group() { - group(); - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/modulevariables-expected.csg b/tests/regression/dumptest/modulevariables-expected.csg new file mode 100644 index 0000000..36bc63b --- /dev/null +++ b/tests/regression/dumptest/modulevariables-expected.csg @@ -0,0 +1,5 @@ +group() { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 23, r2 = 10, center = false); + } +} diff --git a/tests/regression/dumptest/modulevariables-expected.txt b/tests/regression/dumptest/modulevariables-expected.txt deleted file mode 100644 index fed4bbc..0000000 --- a/tests/regression/dumptest/modulevariables-expected.txt +++ /dev/null @@ -1,4 +0,0 @@ - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 10, r1 = 23, r2 = 10, center = false); - } - diff --git a/tests/regression/dumptest/multmatrix-expected.csg b/tests/regression/dumptest/multmatrix-expected.csg new file mode 100644 index 0000000..87e28e2 --- /dev/null +++ b/tests/regression/dumptest/multmatrix-expected.csg @@ -0,0 +1,3 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); +} diff --git a/tests/regression/dumptest/multmatrix-expected.txt b/tests/regression/dumptest/multmatrix-expected.txt deleted file mode 100644 index c3185a3..0000000 --- a/tests/regression/dumptest/multmatrix-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - diff --git a/tests/regression/dumptest/null-polygons-expected.csg b/tests/regression/dumptest/null-polygons-expected.csg new file mode 100644 index 0000000..80125e2 --- /dev/null +++ b/tests/regression/dumptest/null-polygons-expected.csg @@ -0,0 +1,6 @@ +group() { + linear_extrude(height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { + import(file = "null-polygons.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 1); + } + linear_extrude(file = "null-polygons.dxf", layer = "", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); +} diff --git a/tests/regression/dumptest/null-polygons-expected.txt b/tests/regression/dumptest/null-polygons-expected.txt deleted file mode 100644 index d30c909..0000000 --- a/tests/regression/dumptest/null-polygons-expected.txt +++ /dev/null @@ -1,5 +0,0 @@ - linear_extrude(height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1) { - import(file = "null-polygons.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 1); - } - linear_extrude(file = "null-polygons.dxf", layer = "", origin = [0, 0], scale = 1, height = 100, center = false, convexity = 1, $fn = 0, $fa = 12, $fs = 1); - diff --git a/tests/regression/dumptest/polygon-expected.csg b/tests/regression/dumptest/polygon-expected.csg new file mode 100644 index 0000000..d04aec9 --- /dev/null +++ b/tests/regression/dumptest/polygon-expected.csg @@ -0,0 +1,3 @@ +group() { + polygon(points = undef, paths = undef, convexity = 1); +} diff --git a/tests/regression/dumptest/polygon-expected.txt b/tests/regression/dumptest/polygon-expected.txt deleted file mode 100644 index a525d29..0000000 --- a/tests/regression/dumptest/polygon-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - polygon(points = undef, paths = undef, convexity = 1); - diff --git a/tests/regression/dumptest/polygon-illegal-winding-expected.csg b/tests/regression/dumptest/polygon-illegal-winding-expected.csg new file mode 100644 index 0000000..fa0f4ac --- /dev/null +++ b/tests/regression/dumptest/polygon-illegal-winding-expected.csg @@ -0,0 +1,4 @@ +group() { +group() { + polyhedron(points = [[0, -10, 60], [0, 10, 60], [0, 10, 0], [0, -10, 0], [60, -10, 60], [60, 10, 60], [10, -10, 50], [10, 10, 50], [10, 10, 30], [10, -10, 30], [30, -10, 50], [30, 10, 50]], triangles = [[0, 2, 3], [0, 1, 2], [0, 4, 5], [0, 5, 1], [5, 4, 2], [2, 4, 3], [6, 8, 9], [6, 7, 8], [6, 10, 11], [6, 11, 7], [10, 8, 11], [10, 9, 8], [0, 3, 9], [9, 0, 6], [10, 6, 0], [0, 4, 10], [3, 9, 10], [3, 10, 4], [1, 7, 11], [1, 11, 5], [1, 7, 8], [1, 8, 2], [2, 8, 11], [2, 11, 5]], convexity = 1); +}} diff --git a/tests/regression/dumptest/polygon-illegal-winding-expected.txt b/tests/regression/dumptest/polygon-illegal-winding-expected.txt deleted file mode 100644 index 3a4c32b..0000000 --- a/tests/regression/dumptest/polygon-illegal-winding-expected.txt +++ /dev/null @@ -1,3 +0,0 @@ -group() { - polyhedron(points = [[0, -10, 60], [0, 10, 60], [0, 10, 0], [0, -10, 0], [60, -10, 60], [60, 10, 60], [10, -10, 50], [10, 10, 50], [10, 10, 30], [10, -10, 30], [30, -10, 50], [30, 10, 50]], triangles = [[0, 2, 3], [0, 1, 2], [0, 4, 5], [0, 5, 1], [5, 4, 2], [2, 4, 3], [6, 8, 9], [6, 7, 8], [6, 10, 11], [6, 11, 7], [10, 8, 11], [10, 9, 8], [0, 3, 9], [9, 0, 6], [10, 6, 0], [0, 4, 10], [3, 9, 10], [3, 10, 4], [1, 7, 11], [1, 11, 5], [1, 7, 8], [1, 8, 2], [2, 8, 11], [2, 11, 5]], convexity = 1); -} diff --git a/tests/regression/dumptest/polygon-tests-expected.csg b/tests/regression/dumptest/polygon-tests-expected.csg new file mode 100644 index 0000000..56995a5 --- /dev/null +++ b/tests/regression/dumptest/polygon-tests-expected.csg @@ -0,0 +1,36 @@ +group() { + polygon(points = undef, paths = undef, convexity = 1); + polygon(points = [], paths = undef, convexity = 1); + polygon(points = [[], []], paths = undef, convexity = 1); + polygon(points = [[[]]], paths = undef, convexity = 1); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 0], [1, 1]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 1]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 1], [2, 2]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 0], [1, 1], [0, 1]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 0], [1, 1], [0, 1]], paths = [], convexity = 1); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 0], [0.8, 0.5], [1, 1], [0, 1]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [0.5, -0.2], [1, 0], [1.2, 0.5], [1, 1], [0.5, 1.2], [0, 1], [-0.2, 0.5]], paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [0.5, -0.2], [1, 0], [1.2, 0.5], [1, 1], [0.5, 1.2], [0, 1], [-0.2, 0.5]], paths = [[0, 1, 2, 3], [4, 5, 6, 7]], convexity = 1); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[0, 0], [1, 0], [1, 1], [0, 0]], paths = undef, convexity = 1); + } +} diff --git a/tests/regression/dumptest/polygon-tests-expected.txt b/tests/regression/dumptest/polygon-tests-expected.txt deleted file mode 100644 index be66d21..0000000 --- a/tests/regression/dumptest/polygon-tests-expected.txt +++ /dev/null @@ -1,35 +0,0 @@ - polygon(points = undef, paths = undef, convexity = 1); - polygon(points = [], paths = undef, convexity = 1); - polygon(points = [[], []], paths = undef, convexity = 1); - polygon(points = [[[]]], paths = undef, convexity = 1); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 0], [1, 1]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 1]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 1], [2, 2]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 0], [1, 1], [0, 1]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 0], [1, 1], [0, 1]], paths = [], convexity = 1); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 0], [0.8, 0.5], [1, 1], [0, 1]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [0.5, -0.2], [1, 0], [1.2, 0.5], [1, 1], [0.5, 1.2], [0, 1], [-0.2, 0.5]], paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [0.5, -0.2], [1, 0], [1.2, 0.5], [1, 1], [0.5, 1.2], [0, 1], [-0.2, 0.5]], paths = [[0, 1, 2, 3], [4, 5, 6, 7]], convexity = 1); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[0, 0], [1, 0], [1, 1], [0, 0]], paths = undef, convexity = 1); - } - diff --git a/tests/regression/dumptest/polyhedron-expected.csg b/tests/regression/dumptest/polyhedron-expected.csg new file mode 100644 index 0000000..c37a529 --- /dev/null +++ b/tests/regression/dumptest/polyhedron-expected.csg @@ -0,0 +1,3 @@ +group() { + polyhedron(points = undef, triangles = undef, convexity = 1); +} diff --git a/tests/regression/dumptest/polyhedron-expected.txt b/tests/regression/dumptest/polyhedron-expected.txt deleted file mode 100644 index 806c952..0000000 --- a/tests/regression/dumptest/polyhedron-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - polyhedron(points = undef, triangles = undef, convexity = 1); - diff --git a/tests/regression/dumptest/polyhedron-tests-expected.csg b/tests/regression/dumptest/polyhedron-tests-expected.csg new file mode 100644 index 0000000..f59baa2 --- /dev/null +++ b/tests/regression/dumptest/polyhedron-tests-expected.csg @@ -0,0 +1,27 @@ +group() { + group() { + polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 4, 3], [1, 3, 5]], convexity = 1); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 3, 4], [1, 3, 5]], convexity = 1); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 2, 4], [0, 5, 2], [0, 4, 3], [0, 3, 5], [1, 4, 2], [1, 2, 5], [1, 3, 4], [1, 5, 3]], convexity = 1); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + group() { + polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 4, 3], [1, 3, 5]], convexity = 1); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 3, 4], [1, 3, 5]], convexity = 1); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 2, 4], [0, 5, 2], [0, 4, 3], [0, 3, 5], [1, 4, 2], [1, 2, 5], [1, 3, 4], [1, 5, 3]], convexity = 1); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 2], [0, 0, 0, 1]]) { + cube(size = [8, 3, 3], center = true); + } + } + } +} diff --git a/tests/regression/dumptest/polyhedron-tests-expected.txt b/tests/regression/dumptest/polyhedron-tests-expected.txt deleted file mode 100644 index 7de5236..0000000 --- a/tests/regression/dumptest/polyhedron-tests-expected.txt +++ /dev/null @@ -1,26 +0,0 @@ - group() { - polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 4, 3], [1, 3, 5]], convexity = 1); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 3, 4], [1, 3, 5]], convexity = 1); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 2, 4], [0, 5, 2], [0, 4, 3], [0, 3, 5], [1, 4, 2], [1, 2, 5], [1, 3, 4], [1, 5, 3]], convexity = 1); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - group() { - polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 4, 3], [1, 3, 5]], convexity = 1); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 4, 2], [0, 2, 5], [0, 3, 4], [0, 5, 3], [1, 2, 4], [1, 5, 2], [1, 3, 4], [1, 3, 5]], convexity = 1); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polyhedron(points = [[1, 0, 0], [-1, 0, 0], [0, 1, 0], [0, -1, 0], [0, 0, 1], [0, 0, -1]], triangles = [[0, 2, 4], [0, 5, 2], [0, 4, 3], [0, 3, 5], [1, 4, 2], [1, 2, 5], [1, 3, 4], [1, 5, 3]], convexity = 1); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 2], [0, 0, 0, 1]]) { - cube(size = [8, 3, 3], center = true); - } - } - } - diff --git a/tests/regression/dumptest/polyset-reduce-crash-expected.csg b/tests/regression/dumptest/polyset-reduce-crash-expected.csg new file mode 100644 index 0000000..1e83cd2 --- /dev/null +++ b/tests/regression/dumptest/polyset-reduce-crash-expected.csg @@ -0,0 +1,18 @@ +group() { +group() { + multmatrix([[0.809017, -0.587785, 0, 0], [0.587785, 0.809017, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[18.7661, -2.97225], [16.5303, -3.96857], [18.475, -4.43546]], paths = undef, convexity = 1); + polygon(points = [[18.7661, -2.97225], [16.7907, -2.65939], [16.5303, -3.96857]], paths = undef, convexity = 1); + polygon(points = [[19, 0], [17, 0], [16.7907, -2.65939]], paths = undef, convexity = 1); + polygon(points = [[19, 0], [16.7907, -2.65939], [18.7661, -2.97225]], paths = undef, convexity = 1); + polygon(points = [[19, 0], [17, 0], [16.7907, 2.65939]], paths = undef, convexity = 1); + polygon(points = [[19, 0], [16.7907, 2.65939], [18.7661, 2.97225]], paths = undef, convexity = 1); + polygon(points = [[18.7661, 2.97225], [16.7907, 2.65939], [16.5303, 3.96857]], paths = undef, convexity = 1); + polygon(points = [[18.7661, 2.97225], [16.5303, 3.96857], [18.475, 4.43546]], paths = undef, convexity = 1); + } + circle($fn = 0, $fa = 12, $fs = 1, r = 20); + } + } +}} diff --git a/tests/regression/dumptest/polyset-reduce-crash-expected.txt b/tests/regression/dumptest/polyset-reduce-crash-expected.txt deleted file mode 100644 index 50253ff..0000000 --- a/tests/regression/dumptest/polyset-reduce-crash-expected.txt +++ /dev/null @@ -1,17 +0,0 @@ -group() { - multmatrix([[0.809017, -0.587785, 0, 0], [0.587785, 0.809017, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[18.7661, -2.97225], [16.5303, -3.96857], [18.475, -4.43546]], paths = undef, convexity = 1); - polygon(points = [[18.7661, -2.97225], [16.7907, -2.65939], [16.5303, -3.96857]], paths = undef, convexity = 1); - polygon(points = [[19, 0], [17, 0], [16.7907, -2.65939]], paths = undef, convexity = 1); - polygon(points = [[19, 0], [16.7907, -2.65939], [18.7661, -2.97225]], paths = undef, convexity = 1); - polygon(points = [[19, 0], [17, 0], [16.7907, 2.65939]], paths = undef, convexity = 1); - polygon(points = [[19, 0], [16.7907, 2.65939], [18.7661, 2.97225]], paths = undef, convexity = 1); - polygon(points = [[18.7661, 2.97225], [16.7907, 2.65939], [16.5303, 3.96857]], paths = undef, convexity = 1); - polygon(points = [[18.7661, 2.97225], [16.5303, 3.96857], [18.475, 4.43546]], paths = undef, convexity = 1); - } - circle($fn = 0, $fa = 12, $fs = 1, r = 20); - } - } -} diff --git a/tests/regression/dumptest/projection-expected.csg b/tests/regression/dumptest/projection-expected.csg new file mode 100644 index 0000000..d776c2e --- /dev/null +++ b/tests/regression/dumptest/projection-expected.csg @@ -0,0 +1,3 @@ +group() { + projection(cut = false, convexity = 0); +} diff --git a/tests/regression/dumptest/projection-expected.txt b/tests/regression/dumptest/projection-expected.txt deleted file mode 100644 index 85611b4..0000000 --- a/tests/regression/dumptest/projection-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - projection(cut = false, convexity = 0); - diff --git a/tests/regression/dumptest/projection-tests-expected.csg b/tests/regression/dumptest/projection-tests-expected.csg new file mode 100644 index 0000000..86423a1 --- /dev/null +++ b/tests/regression/dumptest/projection-tests-expected.csg @@ -0,0 +1,57 @@ +group() { + projection(cut = false, convexity = 0); + projection(cut = false, convexity = 0); + projection(cut = true, convexity = 0) { + square(size = [1, 1], center = false); + } + linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + projection(cut = false, convexity = 0) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + } + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 9], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + } + } + } + } + multmatrix([[1, 0, 0, 44], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -22], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 5, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + projection(cut = true, convexity = 0) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -4.999999], [0, 0, 0, 1]]) { + cube(size = [10, 10, 10], center = true); + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -44], [0, 0, 1, 0], [0, 0, 0, 1]]) { + linear_extrude(height = 5, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + projection(cut = true, convexity = 0) { + union() { + difference() { + cube(size = [5, 5, 5], center = true); + cube(size = [4, 4, 4], center = true); + } + multmatrix([[1, 0, 0, 2.1], [0, 1, 0, 2.1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + cube(size = [5, 5, 5], center = true); + cube(size = [4, 4, 4], center = true); + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/projection-tests-expected.txt b/tests/regression/dumptest/projection-tests-expected.txt deleted file mode 100644 index 92e6870..0000000 --- a/tests/regression/dumptest/projection-tests-expected.txt +++ /dev/null @@ -1,56 +0,0 @@ - projection(cut = false, convexity = 0); - projection(cut = false, convexity = 0); - projection(cut = true, convexity = 0) { - square(size = [1, 1], center = false); - } - linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - projection(cut = false, convexity = 0) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - } - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 9], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - } - } - } - } - multmatrix([[1, 0, 0, 44], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 20, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 7], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -22], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 5, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - projection(cut = true, convexity = 0) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -4.999999], [0, 0, 0, 1]]) { - cube(size = [10, 10, 10], center = true); - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -44], [0, 0, 1, 0], [0, 0, 0, 1]]) { - linear_extrude(height = 5, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - projection(cut = true, convexity = 0) { - union() { - difference() { - cube(size = [5, 5, 5], center = true); - cube(size = [4, 4, 4], center = true); - } - multmatrix([[1, 0, 0, 2.1], [0, 1, 0, 2.1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - cube(size = [5, 5, 5], center = true); - cube(size = [4, 4, 4], center = true); - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/render-2d-tests-expected.csg b/tests/regression/dumptest/render-2d-tests-expected.csg new file mode 100644 index 0000000..75739b3 --- /dev/null +++ b/tests/regression/dumptest/render-2d-tests-expected.csg @@ -0,0 +1,8 @@ +group() { + render(convexity = 1) { + difference() { + square(size = [100, 100], center = true); + circle($fn = 0, $fa = 12, $fs = 2, r = 30); + } + } +} diff --git a/tests/regression/dumptest/render-2d-tests-expected.txt b/tests/regression/dumptest/render-2d-tests-expected.txt deleted file mode 100644 index 26b916c..0000000 --- a/tests/regression/dumptest/render-2d-tests-expected.txt +++ /dev/null @@ -1,7 +0,0 @@ - render(convexity = 1) { - difference() { - square(size = [100, 100], center = true); - circle($fn = 0, $fa = 12, $fs = 2, r = 30); - } - } - diff --git a/tests/regression/dumptest/render-expected.csg b/tests/regression/dumptest/render-expected.csg new file mode 100644 index 0000000..c599c6b --- /dev/null +++ b/tests/regression/dumptest/render-expected.csg @@ -0,0 +1,3 @@ +group() { + render(convexity = 1); +} diff --git a/tests/regression/dumptest/render-expected.txt b/tests/regression/dumptest/render-expected.txt deleted file mode 100644 index dcc005e..0000000 --- a/tests/regression/dumptest/render-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - render(convexity = 1); - diff --git a/tests/regression/dumptest/render-tests-expected.csg b/tests/regression/dumptest/render-tests-expected.csg new file mode 100644 index 0000000..11aede0 --- /dev/null +++ b/tests/regression/dumptest/render-tests-expected.csg @@ -0,0 +1,72 @@ +group() { + render(convexity = 1); + render(convexity = 1); + group() { + difference() { + cube(size = [100, 100, 100], center = true); + multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + } + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 110], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cube(size = [100, 100, 100], center = true); + multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + group() { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + render(convexity = 2) { + group() { + difference() { + cube(size = [20, 20, 150], center = true); + multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); + } + } + } + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/render-tests-expected.txt b/tests/regression/dumptest/render-tests-expected.txt deleted file mode 100644 index 6914270..0000000 --- a/tests/regression/dumptest/render-tests-expected.txt +++ /dev/null @@ -1,71 +0,0 @@ - render(convexity = 1); - render(convexity = 1); - group() { - difference() { - cube(size = [100, 100, 100], center = true); - multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - } - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 110], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cube(size = [100, 100, 100], center = true); - multmatrix([[1, 0, 0, -50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1, -1.22465e-16, 0, 0], [1.22465e-16, -1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - group() { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, -50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[-1.83697e-16, 1, 0, 0], [-1, -1.83697e-16, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - render(convexity = 2) { - group() { - difference() { - cube(size = [20, 20, 150], center = true); - multmatrix([[1, 0, 0, -10], [0, 1, 0, -10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 80, r1 = 10, r2 = 10, center = true); - } - } - } - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/resize-2d-tests-expected.csg b/tests/regression/dumptest/resize-2d-tests-expected.csg new file mode 100644 index 0000000..5f8d8b5 --- /dev/null +++ b/tests/regression/dumptest/resize-2d-tests-expected.csg @@ -0,0 +1,176 @@ +group() { + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, -16], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[3, 0, 0, 0], [0, 3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 10, $fa = 12, $fs = 2, r = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, -16], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[3, 0, 0, 0], [0, 3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + } + } + multmatrix([[1, 0, 0, -16], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[3, 0, 0, 0], [0, 3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [5, 1], center = false); + } + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [15,15,0], auto = [0,0,0]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 10, $fa = 12, $fs = 2, r = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [15,15,0], auto = [0,0,0]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [15,15,0], auto = [0,0,0]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [5, 1], center = false); + } + } + } + } + } + color([0, 0.501961, 0, 1]) { + multmatrix([[1, 0, 0, 16], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [15,0,0], auto = [1,1,1]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 10, $fa = 12, $fs = 2, r = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, 16], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,15,0], auto = [1,1,1]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + } + } + multmatrix([[1, 0, 0, 16], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,15,0], auto = [1,0,0]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [5, 1], center = false); + } + } + } + } + } + } + color([1, 0.752941, 0.796078, 1]) { + multmatrix([[1, 0, 0, 32], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,0,0], auto = [0,1,0]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 10, $fa = 12, $fs = 2, r = 1); + } + } + } + } + } + multmatrix([[1, 0, 0, 32], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,0,15], auto = [1,1,1]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = false); + } + } + } + } + } + multmatrix([[1, 0, 0, 32], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,0,15], auto = [0,0,0]) { + group() { + difference() { + square(size = [5, 5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [5, 1], center = false); + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/resize-2d-tests-expected.txt b/tests/regression/dumptest/resize-2d-tests-expected.txt deleted file mode 100644 index 0bbdd66..0000000 --- a/tests/regression/dumptest/resize-2d-tests-expected.txt +++ /dev/null @@ -1,175 +0,0 @@ - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, -16], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[3, 0, 0, 0], [0, 3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 10, $fa = 12, $fs = 2, r = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, -16], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[3, 0, 0, 0], [0, 3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - } - } - multmatrix([[1, 0, 0, -16], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[3, 0, 0, 0], [0, 3, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [5, 1], center = false); - } - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [15,15,0], auto = [0,0,0]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 10, $fa = 12, $fs = 2, r = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [15,15,0], auto = [0,0,0]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [15,15,0], auto = [0,0,0]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [5, 1], center = false); - } - } - } - } - } - color([0, 0.501961, 0, 1]) { - multmatrix([[1, 0, 0, 16], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [15,0,0], auto = [1,1,1]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 10, $fa = 12, $fs = 2, r = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, 16], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,15,0], auto = [1,1,1]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - } - } - multmatrix([[1, 0, 0, 16], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,15,0], auto = [1,0,0]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [5, 1], center = false); - } - } - } - } - } - } - color([1, 0.752941, 0.796078, 1]) { - multmatrix([[1, 0, 0, 32], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,0,0], auto = [0,1,0]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 10, $fa = 12, $fs = 2, r = 1); - } - } - } - } - } - multmatrix([[1, 0, 0, 32], [0, 1, 0, 16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,0,15], auto = [1,1,1]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = false); - } - } - } - } - } - multmatrix([[1, 0, 0, 32], [0, 1, 0, 32], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,0,15], auto = [0,0,0]) { - group() { - difference() { - square(size = [5, 5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2.5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [5, 1], center = false); - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/resize-tests-expected.csg b/tests/regression/dumptest/resize-tests-expected.csg new file mode 100644 index 0000000..1e7888a --- /dev/null +++ b/tests/regression/dumptest/resize-tests-expected.csg @@ -0,0 +1,271 @@ +group() { + color([1, 0, 0, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [5, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [1, 6, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 30], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [1, 1, 7], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [5, 6, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 60], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [1, 6, 7], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 50], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [5, 1, 7], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 70], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [8, 9, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 80], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [9, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 90], [0, 0, 1, -10], [0, 0, 0, 1]]) { + cube(size = [5, 6, 7], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,6,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,0,7], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,6,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 60], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,6,7], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,0,7], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 70], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [8,9,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 80], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [9,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 90], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,6,7], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + color([0, 0, 1, 1]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 10.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [5,0,0], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 23], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [0,6,0], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 30.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [0,0,7], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 43], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [5,6,0], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 50.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [5,0,7], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 63], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [0,6,7], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 74.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [8,9,0], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 4.5], [0, 1, 0, 80.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [9,0,0], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 93], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [5,6,7], auto = [0,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + } + color([0, 0.501961, 0, 1]) { + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,0,0], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,6,0], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,0,7], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,6,0], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,0,7], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 60], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [0,6,7], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 70], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [8,9,0], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 80], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [9,0,0], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 90], [0, 0, 1, 0], [0, 0, 0, 1]]) { + resize(newsize = [5,6,7], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + } + color([0.501961, 0, 0.501961, 1]) { + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [1, 1, 1], center = false); + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [5,0,0], auto = [1,1,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [6,0,0], auto = [1,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 13.5], [0, 1, 0, 33.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [7,0,0], auto = [1,0,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 1); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [6,0,0], auto = [1,0,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 50], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [7,0,7], auto = [0,1,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 13.5], [0, 1, 0, 63.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [7,0,0], auto = [0,1,0]) { + sphere($fn = 8, $fa = 12, $fs = 2, r = 1); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 70], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [8,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 80], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [9,0,0], auto = [0,0,1]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 90], [0, 0, 1, 10], [0, 0, 0, 1]]) { + resize(newsize = [0,0,7], auto = [1,1,0]) { + cube(size = [1, 1, 1], center = false); + } + } + } + color([1, 0.752941, 0.796078, 1]) { + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [4,4,4], auto = [0,0,0]) { + resize(newsize = [5000,100,1000], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [-5,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [-5,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 30], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [0,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [0,0,0], auto = [0,0,0]) { + cube(size = [1, 1, 1], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 50], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [0.5,0,7], auto = [0,0,0]) { + cube(size = [0.5, 1, 1000], center = false); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 60], [0, 0, 1, -10], [0, 0, 0, 1]]) { + resize(newsize = [0,0,0.5], auto = [0,0,0]) { + cube(size = [6, 6, 1e+10], center = false); + } + } + } +} diff --git a/tests/regression/dumptest/resize-tests-expected.txt b/tests/regression/dumptest/resize-tests-expected.txt deleted file mode 100644 index f31290c..0000000 --- a/tests/regression/dumptest/resize-tests-expected.txt +++ /dev/null @@ -1,270 +0,0 @@ - color([1, 0, 0, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [5, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [1, 6, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 30], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [1, 1, 7], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [5, 6, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 60], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [1, 6, 7], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 50], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [5, 1, 7], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 70], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [8, 9, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 80], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [9, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 90], [0, 0, 1, -10], [0, 0, 0, 1]]) { - cube(size = [5, 6, 7], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,6,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,0,7], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,6,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 60], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,6,7], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,0,7], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 70], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [8,9,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 80], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [9,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 90], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,6,7], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - color([0, 0, 1, 1]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 10.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [5,0,0], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 23], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [0,6,0], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 30.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [0,0,7], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 43], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [5,6,0], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 50.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [5,0,7], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 0.5], [0, 1, 0, 63], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [0,6,7], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 74.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [8,9,0], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 4.5], [0, 1, 0, 80.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [9,0,0], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, 2.5], [0, 1, 0, 93], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [5,6,7], auto = [0,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - } - color([0, 0.501961, 0, 1]) { - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,0,0], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,6,0], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,0,7], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,6,0], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,0,7], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 60], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [0,6,7], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 70], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [8,9,0], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 80], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [9,0,0], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 90], [0, 0, 1, 0], [0, 0, 0, 1]]) { - resize(newsize = [5,6,7], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - } - color([0.501961, 0, 0.501961, 1]) { - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [1, 1, 1], center = false); - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [5,0,0], auto = [1,1,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [6,0,0], auto = [1,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 13.5], [0, 1, 0, 33.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [7,0,0], auto = [1,0,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 1); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [6,0,0], auto = [1,0,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 50], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [7,0,7], auto = [0,1,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 13.5], [0, 1, 0, 63.5], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [7,0,0], auto = [0,1,0]) { - sphere($fn = 8, $fa = 12, $fs = 2, r = 1); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 70], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [8,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 80], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [9,0,0], auto = [0,0,1]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 90], [0, 0, 1, 10], [0, 0, 0, 1]]) { - resize(newsize = [0,0,7], auto = [1,1,0]) { - cube(size = [1, 1, 1], center = false); - } - } - } - color([1, 0.752941, 0.796078, 1]) { - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [4,4,4], auto = [0,0,0]) { - resize(newsize = [5000,100,1000], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [-5,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 20], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [-5,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 30], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [0,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 40], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [0,0,0], auto = [0,0,0]) { - cube(size = [1, 1, 1], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 50], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [0.5,0,7], auto = [0,0,0]) { - cube(size = [0.5, 1, 1000], center = false); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 60], [0, 0, 1, -10], [0, 0, 0, 1]]) { - resize(newsize = [0,0,0.5], auto = [0,0,0]) { - cube(size = [6, 6, 1e+10], center = false); - } - } - } - diff --git a/tests/regression/dumptest/root-modifier-expected.csg b/tests/regression/dumptest/root-modifier-expected.csg new file mode 100644 index 0000000..d7666d6 --- /dev/null +++ b/tests/regression/dumptest/root-modifier-expected.csg @@ -0,0 +1,6 @@ +group() { + difference() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 10); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); + } +} diff --git a/tests/regression/dumptest/root-modifier-expected.txt b/tests/regression/dumptest/root-modifier-expected.txt deleted file mode 100644 index c0f1da2..0000000 --- a/tests/regression/dumptest/root-modifier-expected.txt +++ /dev/null @@ -1,5 +0,0 @@ - difference() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 10); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 30, r1 = 6, r2 = 6, center = true); - } - diff --git a/tests/regression/dumptest/root-modifier-if-expected.csg b/tests/regression/dumptest/root-modifier-if-expected.csg new file mode 100644 index 0000000..0cc2d3e --- /dev/null +++ b/tests/regression/dumptest/root-modifier-if-expected.csg @@ -0,0 +1,8 @@ +group() { + group() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + group() { + cube(size = [5, 5, 5], center = false); + } +} diff --git a/tests/regression/dumptest/root-modifier-if-expected.txt b/tests/regression/dumptest/root-modifier-if-expected.txt deleted file mode 100644 index dfcd15a..0000000 --- a/tests/regression/dumptest/root-modifier-if-expected.txt +++ /dev/null @@ -1,7 +0,0 @@ - group() { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - group() { - cube(size = [5, 5, 5], center = false); - } - diff --git a/tests/regression/dumptest/rotate-expected.csg b/tests/regression/dumptest/rotate-expected.csg new file mode 100644 index 0000000..87e28e2 --- /dev/null +++ b/tests/regression/dumptest/rotate-expected.csg @@ -0,0 +1,3 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); +} diff --git a/tests/regression/dumptest/rotate-expected.txt b/tests/regression/dumptest/rotate-expected.txt deleted file mode 100644 index c3185a3..0000000 --- a/tests/regression/dumptest/rotate-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - diff --git a/tests/regression/dumptest/rotate_extrude-expected.csg b/tests/regression/dumptest/rotate_extrude-expected.csg new file mode 100644 index 0000000..54f06b3 --- /dev/null +++ b/tests/regression/dumptest/rotate_extrude-expected.csg @@ -0,0 +1,3 @@ +group() { + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/rotate_extrude-expected.txt b/tests/regression/dumptest/rotate_extrude-expected.txt deleted file mode 100644 index c212d76..0000000 --- a/tests/regression/dumptest/rotate_extrude-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/rotate_extrude-tests-expected.csg b/tests/regression/dumptest/rotate_extrude-tests-expected.csg new file mode 100644 index 0000000..a86dd8f --- /dev/null +++ b/tests/regression/dumptest/rotate_extrude-tests-expected.csg @@ -0,0 +1,53 @@ +group() { + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { + cube(size = [1, 1, 1], center = false); + } + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, -20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + circle($fn = 0, $fa = 12, $fs = 2, r = 8); + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [100, 100, 100], center = true); + } + } + } + multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { + difference() { + difference() { + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 10); + } + } + rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 0, $fa = 12, $fs = 2, r = 8); + } + } + } + multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [100, 100, 100], center = true); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -60], [0, 0, 1, 0], [0, 0, 0, 1]]) { + rotate_extrude(convexity = 1, $fn = 1, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 1, $fa = 12, $fs = 2, r = 10); + } + } + } +} diff --git a/tests/regression/dumptest/rotate_extrude-tests-expected.txt b/tests/regression/dumptest/rotate_extrude-tests-expected.txt deleted file mode 100644 index 023d78d..0000000 --- a/tests/regression/dumptest/rotate_extrude-tests-expected.txt +++ /dev/null @@ -1,52 +0,0 @@ - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2); - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { - cube(size = [1, 1, 1], center = false); - } - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, -20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - circle($fn = 0, $fa = 12, $fs = 2, r = 8); - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [100, 100, 100], center = true); - } - } - } - multmatrix([[1, 0, 0, 50], [0, 1, 0, 50], [0, 0, 1, 0], [0, 0, 0, 1]]) { - difference() { - difference() { - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 10); - } - } - rotate_extrude(convexity = 1, $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 0, $fa = 12, $fs = 2, r = 8); - } - } - } - multmatrix([[1, 0, 0, -50], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [100, 100, 100], center = true); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -60], [0, 0, 1, 0], [0, 0, 0, 1]]) { - rotate_extrude(convexity = 1, $fn = 1, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 1, $fa = 12, $fs = 2, r = 10); - } - } - } - diff --git a/tests/regression/dumptest/rotate_extrude_dxf-tests-expected.csg b/tests/regression/dumptest/rotate_extrude_dxf-tests-expected.csg new file mode 100644 index 0000000..8e9963c --- /dev/null +++ b/tests/regression/dumptest/rotate_extrude_dxf-tests-expected.csg @@ -0,0 +1,3 @@ +group() { + rotate_extrude(file = "../../dxf/open-polyline.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); +} diff --git a/tests/regression/dumptest/rotate_extrude_dxf-tests-expected.txt b/tests/regression/dumptest/rotate_extrude_dxf-tests-expected.txt deleted file mode 100644 index f79e0ce..0000000 --- a/tests/regression/dumptest/rotate_extrude_dxf-tests-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - rotate_extrude(file = "../../dxf/open-polyline.dxf", layer = "", origin = [0, 0], scale = 1, convexity = 1, $fn = 0, $fa = 12, $fs = 2); - diff --git a/tests/regression/dumptest/scale-expected.csg b/tests/regression/dumptest/scale-expected.csg new file mode 100644 index 0000000..87e28e2 --- /dev/null +++ b/tests/regression/dumptest/scale-expected.csg @@ -0,0 +1,3 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); +} diff --git a/tests/regression/dumptest/scale-expected.txt b/tests/regression/dumptest/scale-expected.txt deleted file mode 100644 index c3185a3..0000000 --- a/tests/regression/dumptest/scale-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - diff --git a/tests/regression/dumptest/scale2D-tests-expected.csg b/tests/regression/dumptest/scale2D-tests-expected.csg new file mode 100644 index 0000000..b20a975 --- /dev/null +++ b/tests/regression/dumptest/scale2D-tests-expected.csg @@ -0,0 +1,35 @@ +group() { + multmatrix([[2, 0, 0, 0], [0, 1.33333333333, 0, 0], [0, 0, 2, 0], [0, 0, 0, 1]]) { + group() { + square(size = [2, 3], center = true); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2, 0, 0, 0], [0, 1.33333333333, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + square(size = [2, 3], center = true); + } + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2, 0, 0, 0], [0, 2, 0, 0], [0, 0, 2, 0], [0, 0, 0, 1]]) { + group() { + square(size = [2, 3], center = true); + } + } + } + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + square(size = [2, 3], center = true); + } + } + } + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[0, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + square(size = [2, 3], center = true); + } + } + } +} diff --git a/tests/regression/dumptest/scale2D-tests-expected.txt b/tests/regression/dumptest/scale2D-tests-expected.txt deleted file mode 100644 index 9465b8c..0000000 --- a/tests/regression/dumptest/scale2D-tests-expected.txt +++ /dev/null @@ -1,34 +0,0 @@ - multmatrix([[2, 0, 0, 0], [0, 1.33333333333, 0, 0], [0, 0, 2, 0], [0, 0, 0, 1]]) { - group() { - square(size = [2, 3], center = true); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2, 0, 0, 0], [0, 1.33333333333, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - square(size = [2, 3], center = true); - } - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2, 0, 0, 0], [0, 2, 0, 0], [0, 0, 2, 0], [0, 0, 0, 1]]) { - group() { - square(size = [2, 3], center = true); - } - } - } - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - square(size = [2, 3], center = true); - } - } - } - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[0, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - square(size = [2, 3], center = true); - } - } - } - diff --git a/tests/regression/dumptest/scale3D-tests-expected.csg b/tests/regression/dumptest/scale3D-tests-expected.csg new file mode 100644 index 0000000..89bf1af --- /dev/null +++ b/tests/regression/dumptest/scale3D-tests-expected.csg @@ -0,0 +1,44 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 2, 0, 0], [0, 0, 3, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + } + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + } + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[2, 0, 0, 0], [0, 2, 0, 0], [0, 0, 2, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + } + } + } + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + } + } + } + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[0, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + } + } + } + linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); + } + } + } +} diff --git a/tests/regression/dumptest/scale3D-tests-expected.txt b/tests/regression/dumptest/scale3D-tests-expected.txt deleted file mode 100644 index e802117..0000000 --- a/tests/regression/dumptest/scale3D-tests-expected.txt +++ /dev/null @@ -1,43 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 2, 0, 0], [0, 0, 3, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - } - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - } - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[2, 0, 0, 0], [0, 2, 0, 0], [0, 0, 2, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - } - } - } - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - } - } - } - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[0, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - } - } - } - linear_extrude(height = 100, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 8, $fa = 12, $fs = 2, h = 1, r1 = 1, r2 = 1, center = true); - } - } - } - diff --git a/tests/regression/dumptest/sphere-expected.csg b/tests/regression/dumptest/sphere-expected.csg new file mode 100644 index 0000000..8c5b075 --- /dev/null +++ b/tests/regression/dumptest/sphere-expected.csg @@ -0,0 +1,3 @@ +group() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 1); +} diff --git a/tests/regression/dumptest/sphere-expected.txt b/tests/regression/dumptest/sphere-expected.txt deleted file mode 100644 index 1b8369f..0000000 --- a/tests/regression/dumptest/sphere-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - sphere($fn = 0, $fa = 12, $fs = 2, r = 1); - diff --git a/tests/regression/dumptest/sphere-tests-expected.csg b/tests/regression/dumptest/sphere-tests-expected.csg new file mode 100644 index 0000000..45c0858 --- /dev/null +++ b/tests/regression/dumptest/sphere-tests-expected.csg @@ -0,0 +1,33 @@ +group() { + sphere($fn = 0, $fa = 12, $fs = 2, r = 1); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 0); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 10, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 15, $fa = 12, $fs = 2, r = 5); + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 20, $fs = 0.3, r = 5); + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 30, $fs = 0.3, r = 5); + } + multmatrix([[1, 0, 0, 22], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0, $fa = 40, $fs = 0.3, r = 5); + } + multmatrix([[1, 0, 0, 11], [0, 1, 0, 22], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 0.1, $fa = 12, $fs = 2, r = 5); + } +} diff --git a/tests/regression/dumptest/sphere-tests-expected.txt b/tests/regression/dumptest/sphere-tests-expected.txt deleted file mode 100644 index 461e946..0000000 --- a/tests/regression/dumptest/sphere-tests-expected.txt +++ /dev/null @@ -1,32 +0,0 @@ - sphere($fn = 0, $fa = 12, $fs = 2, r = 1); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 0); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 10, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 15, $fa = 12, $fs = 2, r = 5); - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, -11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 20, $fs = 0.3, r = 5); - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 30, $fs = 0.3, r = 5); - } - multmatrix([[1, 0, 0, 22], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0, $fa = 40, $fs = 0.3, r = 5); - } - multmatrix([[1, 0, 0, 11], [0, 1, 0, 22], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 0.1, $fa = 12, $fs = 2, r = 5); - } - diff --git a/tests/regression/dumptest/square-expected.csg b/tests/regression/dumptest/square-expected.csg new file mode 100644 index 0000000..a4a24d8 --- /dev/null +++ b/tests/regression/dumptest/square-expected.csg @@ -0,0 +1,3 @@ +group() { + square(size = [1, 1], center = false); +} diff --git a/tests/regression/dumptest/square-expected.txt b/tests/regression/dumptest/square-expected.txt deleted file mode 100644 index 0f14657..0000000 --- a/tests/regression/dumptest/square-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - square(size = [1, 1], center = false); - diff --git a/tests/regression/dumptest/square-tests-expected.csg b/tests/regression/dumptest/square-tests-expected.csg new file mode 100644 index 0000000..6569da4 --- /dev/null +++ b/tests/regression/dumptest/square-tests-expected.csg @@ -0,0 +1,24 @@ +group() { + square(size = [1, 1], center = false); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 1], center = true); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [0, 0], center = true); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 0], center = true); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [0, 1], center = true); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [1, 2], center = true); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + square(size = [2, 1], center = true); + } +} diff --git a/tests/regression/dumptest/square-tests-expected.txt b/tests/regression/dumptest/square-tests-expected.txt deleted file mode 100644 index c23c83d..0000000 --- a/tests/regression/dumptest/square-tests-expected.txt +++ /dev/null @@ -1,23 +0,0 @@ - square(size = [1, 1], center = false); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 1], center = true); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [0, 0], center = true); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 0], center = true); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [0, 1], center = true); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [1, 2], center = true); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - square(size = [2, 1], center = true); - } - diff --git a/tests/regression/dumptest/subdiv-expected.csg b/tests/regression/dumptest/subdiv-expected.csg new file mode 100644 index 0000000..bc40dc2 --- /dev/null +++ b/tests/regression/dumptest/subdiv-expected.csg @@ -0,0 +1,3 @@ +group() { + subdiv(level = 1, convexity = 0); +} diff --git a/tests/regression/dumptest/subdiv-expected.txt b/tests/regression/dumptest/subdiv-expected.txt deleted file mode 100644 index cd7d37e..0000000 --- a/tests/regression/dumptest/subdiv-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - subdiv(level = 1, convexity = 0); - diff --git a/tests/regression/dumptest/surface-expected.csg b/tests/regression/dumptest/surface-expected.csg new file mode 100644 index 0000000..4c9b5b8 --- /dev/null +++ b/tests/regression/dumptest/surface-expected.csg @@ -0,0 +1,3 @@ +group() { + surface(file = "", center = false); +} diff --git a/tests/regression/dumptest/surface-expected.txt b/tests/regression/dumptest/surface-expected.txt deleted file mode 100644 index 7ed73bd..0000000 --- a/tests/regression/dumptest/surface-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - surface(file = "", center = false); - diff --git a/tests/regression/dumptest/surface-simple-expected.csg b/tests/regression/dumptest/surface-simple-expected.csg new file mode 100644 index 0000000..4def193 --- /dev/null +++ b/tests/regression/dumptest/surface-simple-expected.csg @@ -0,0 +1,6 @@ +group() { + surface(file = "surface-simple.dat", center = true); + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + surface(file = "surface-simple2.dat", center = true); + } +} diff --git a/tests/regression/dumptest/surface-simple-expected.txt b/tests/regression/dumptest/surface-simple-expected.txt deleted file mode 100644 index 48c918f..0000000 --- a/tests/regression/dumptest/surface-simple-expected.txt +++ /dev/null @@ -1,5 +0,0 @@ - surface(file = "surface-simple.dat", center = true); - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - surface(file = "surface-simple2.dat", center = true); - } - diff --git a/tests/regression/dumptest/surface-tests-expected.csg b/tests/regression/dumptest/surface-tests-expected.csg new file mode 100644 index 0000000..18246f5 --- /dev/null +++ b/tests/regression/dumptest/surface-tests-expected.csg @@ -0,0 +1,4 @@ +group() { + surface(file = "", center = false); + surface(file = "surface.dat", center = true); +} diff --git a/tests/regression/dumptest/surface-tests-expected.txt b/tests/regression/dumptest/surface-tests-expected.txt deleted file mode 100644 index e3b59c5..0000000 --- a/tests/regression/dumptest/surface-tests-expected.txt +++ /dev/null @@ -1,3 +0,0 @@ - surface(file = "", center = false); - surface(file = "surface.dat", center = true); - diff --git a/tests/regression/dumptest/testcolornames-expected.csg b/tests/regression/dumptest/testcolornames-expected.csg new file mode 100644 index 0000000..06cb365 --- /dev/null +++ b/tests/regression/dumptest/testcolornames-expected.csg @@ -0,0 +1,707 @@ +group() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.803922, 0.360784, 0.360784, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.941176, 0.501961, 0.501961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.980392, 0.501961, 0.447059, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.913725, 0.588235, 0.478431, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.627451, 0.478431, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.862745, 0.0784314, 0.235294, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.698039, 0.133333, 0.133333, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.545098, 0, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.752941, 0.796078, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.713726, 0.756863, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.411765, 0.705882, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.0784314, 0.576471, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.780392, 0.0823529, 0.521569, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.858824, 0.439216, 0.576471, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.627451, 0.478431, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.498039, 0.313726, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.388235, 0.278431, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.270588, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.54902, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.647059, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.843137, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 1, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 1, 0.878431, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.980392, 0.803922, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.980392, 0.980392, 0.823529, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.937255, 0.835294, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.894118, 0.709804, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.854902, 0.72549, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.933333, 0.909804, 0.666667, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.941176, 0.901961, 0.54902, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.741176, 0.717647, 0.419608, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.901961, 0.901961, 0.980392, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.847059, 0.74902, 0.847059, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.866667, 0.627451, 0.866667, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.933333, 0.509804, 0.933333, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.854902, 0.439216, 0.839216, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.729412, 0.333333, 0.827451, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.576471, 0.439216, 0.858824, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.541176, 0.168627, 0.886275, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.580392, 0, 0.827451, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.6, 0.196078, 0.8, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.545098, 0, 0.545098, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.501961, 0, 0.501961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.294118, 0, 0.509804, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.282353, 0.239216, 0.545098, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.415686, 0.352941, 0.803922, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.482353, 0.407843, 0.933333, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.678431, 1, 0.184314, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.498039, 1, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.486275, 0.988235, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 1, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.196078, 0.803922, 0.196078, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.596078, 0.984314, 0.596078, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.564706, 0.933333, 0.564706, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.980392, 0.603922, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 1, 0.498039, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.235294, 0.701961, 0.443137, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.180392, 0.545098, 0.341176, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.133333, 0.545098, 0.133333, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.501961, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.392157, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.603922, 0.803922, 0.196078, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.419608, 0.556863, 0.137255, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.501961, 0.501961, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.333333, 0.419608, 0.184314, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.4, 0.803922, 0.666667, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.560784, 0.737255, 0.560784, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.12549, 0.698039, 0.666667, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.545098, 0.545098, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.501961, 0.501961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 1, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 1, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.878431, 1, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.686275, 0.933333, 0.933333, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.498039, 1, 0.831373, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.25098, 0.878431, 0.815686, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.282353, 0.819608, 0.8, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.807843, 0.819608, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.372549, 0.619608, 0.627451, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.27451, 0.509804, 0.705882, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.690196, 0.768627, 0.870588, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.690196, 0.878431, 0.901961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.678431, 0.847059, 0.901961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.529412, 0.807843, 0.921569, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.529412, 0.807843, 0.980392, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0.74902, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.117647, 0.564706, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.392157, 0.584314, 0.929412, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.254902, 0.411765, 0.882353, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0, 0.803922, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0, 0.545098, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0, 0.501961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.0980392, 0.0980392, 0.439216, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.972549, 0.862745, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.921569, 0.803922, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.894118, 0.768627, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.870588, 0.678431, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.960784, 0.870588, 0.701961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.870588, 0.721569, 0.529412, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.823529, 0.705882, 0.54902, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.737255, 0.560784, 0.560784, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.956863, 0.643137, 0.376471, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.854902, 0.647059, 0.12549, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.721569, 0.52549, 0.0431373, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.803922, 0.521569, 0.247059, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.823529, 0.411765, 0.117647, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.545098, 0.270588, 0.0745098, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.627451, 0.321569, 0.176471, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.647059, 0.164706, 0.164706, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.501961, 0, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 1, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.980392, 0.980392, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.941176, 1, 0.941176, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.960784, 1, 0.980392, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.941176, 1, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.941176, 0.972549, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.972549, 0.972549, 1, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.960784, 0.960784, 0.960784, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.960784, 0.933333, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.960784, 0.960784, 0.862745, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.992157, 0.960784, 0.901961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.980392, 0.941176, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 1, 0.941176, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.980392, 0.921569, 0.843137, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.980392, 0.941176, 0.901961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.941176, 0.960784, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([1, 0.894118, 0.882353, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 9], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.862745, 0.862745, 0.862745, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 10], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.827451, 0.827451, 0.827451, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.752941, 0.752941, 0.752941, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.662745, 0.662745, 0.662745, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.501961, 0.501961, 0.501961, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.411765, 0.411765, 0.411765, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.466667, 0.533333, 0.6, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.439216, 0.501961, 0.564706, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0.184314, 0.309804, 0.309804, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { + color([0, 0, 0, 1]) { + sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); + } + } +} diff --git a/tests/regression/dumptest/testcolornames-expected.txt b/tests/regression/dumptest/testcolornames-expected.txt deleted file mode 100644 index 63b5e70..0000000 --- a/tests/regression/dumptest/testcolornames-expected.txt +++ /dev/null @@ -1,706 +0,0 @@ - multmatrix([[1, 0, 0, 1], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.803922, 0.360784, 0.360784, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.941176, 0.501961, 0.501961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.980392, 0.501961, 0.447059, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.913725, 0.588235, 0.478431, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.627451, 0.478431, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.862745, 0.0784314, 0.235294, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.698039, 0.133333, 0.133333, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.545098, 0, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.752941, 0.796078, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.713726, 0.756863, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.411765, 0.705882, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.0784314, 0.576471, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.780392, 0.0823529, 0.521569, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.858824, 0.439216, 0.576471, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.627451, 0.478431, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.498039, 0.313726, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.388235, 0.278431, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.270588, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.54902, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.647059, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.843137, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 1, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 1, 0.878431, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.980392, 0.803922, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.980392, 0.980392, 0.823529, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.937255, 0.835294, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.894118, 0.709804, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.854902, 0.72549, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.933333, 0.909804, 0.666667, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.941176, 0.901961, 0.54902, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.741176, 0.717647, 0.419608, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.901961, 0.901961, 0.980392, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.847059, 0.74902, 0.847059, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.866667, 0.627451, 0.866667, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.933333, 0.509804, 0.933333, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.854902, 0.439216, 0.839216, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.729412, 0.333333, 0.827451, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.576471, 0.439216, 0.858824, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.541176, 0.168627, 0.886275, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.580392, 0, 0.827451, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.6, 0.196078, 0.8, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.545098, 0, 0.545098, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.501961, 0, 0.501961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.294118, 0, 0.509804, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.282353, 0.239216, 0.545098, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.415686, 0.352941, 0.803922, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.482353, 0.407843, 0.933333, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.678431, 1, 0.184314, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.498039, 1, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.486275, 0.988235, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 1, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.196078, 0.803922, 0.196078, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.596078, 0.984314, 0.596078, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.564706, 0.933333, 0.564706, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.980392, 0.603922, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 1, 0.498039, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.235294, 0.701961, 0.443137, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.180392, 0.545098, 0.341176, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.133333, 0.545098, 0.133333, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.501961, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.392157, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.603922, 0.803922, 0.196078, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.419608, 0.556863, 0.137255, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.501961, 0.501961, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.333333, 0.419608, 0.184314, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.4, 0.803922, 0.666667, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.560784, 0.737255, 0.560784, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.12549, 0.698039, 0.666667, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.545098, 0.545098, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.501961, 0.501961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 1, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 1, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.878431, 1, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.686275, 0.933333, 0.933333, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.498039, 1, 0.831373, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.25098, 0.878431, 0.815686, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.282353, 0.819608, 0.8, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.807843, 0.819608, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.372549, 0.619608, 0.627451, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.27451, 0.509804, 0.705882, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.690196, 0.768627, 0.870588, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.690196, 0.878431, 0.901961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.678431, 0.847059, 0.901961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.529412, 0.807843, 0.921569, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.529412, 0.807843, 0.980392, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0.74902, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.117647, 0.564706, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.392157, 0.584314, 0.929412, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.254902, 0.411765, 0.882353, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0, 0.803922, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0, 0.545098, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0, 0.501961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.0980392, 0.0980392, 0.439216, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.972549, 0.862745, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.921569, 0.803922, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.894118, 0.768627, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.870588, 0.678431, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 9], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.960784, 0.870588, 0.701961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.870588, 0.721569, 0.529412, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.823529, 0.705882, 0.54902, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.737255, 0.560784, 0.560784, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.956863, 0.643137, 0.376471, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.854902, 0.647059, 0.12549, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.721569, 0.52549, 0.0431373, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.803922, 0.521569, 0.247059, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.823529, 0.411765, 0.117647, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.545098, 0.270588, 0.0745098, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.627451, 0.321569, 0.176471, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 10], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.647059, 0.164706, 0.164706, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.501961, 0, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 1, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.980392, 0.980392, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.941176, 1, 0.941176, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.960784, 1, 0.980392, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.941176, 1, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.941176, 0.972549, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.972549, 0.972549, 1, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.960784, 0.960784, 0.960784, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 11], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.960784, 0.933333, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.960784, 0.960784, 0.862745, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.992157, 0.960784, 0.901961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.980392, 0.941176, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 1, 0.941176, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.980392, 0.921569, 0.843137, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.980392, 0.941176, 0.901961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.941176, 0.960784, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([1, 0.894118, 0.882353, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 9], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.862745, 0.862745, 0.862745, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 10], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.827451, 0.827451, 0.827451, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.752941, 0.752941, 0.752941, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.662745, 0.662745, 0.662745, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.501961, 0.501961, 0.501961, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.411765, 0.411765, 0.411765, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.466667, 0.533333, 0.6, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.439216, 0.501961, 0.564706, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0.184314, 0.309804, 0.309804, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 13], [0, 0, 1, 0], [0, 0, 0, 1]]) { - color([0, 0, 0, 1]) { - sphere($fn = 5, $fa = 12, $fs = 2, r = 0.8); - } - } - diff --git a/tests/regression/dumptest/text-search-test-expected.csg b/tests/regression/dumptest/text-search-test-expected.csg new file mode 100644 index 0000000..72e6572 --- /dev/null +++ b/tests/regression/dumptest/text-search-test-expected.csg @@ -0,0 +1,849 @@ +group() { + group(); + group() { + multmatrix([[1, 0, 0, -60], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 2], [6, 2], [6, 1], [3, 2], [3, 6], [5, 6], [5, 2]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], [12, 13, 14, 15]], convexity = 1); + } + multmatrix([[1, 0, 0, -52], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 0], [1, 6], [6, 6], [6, 5], [7, 5], [7, 3], [6, 3], [6, 2], [3, 2], [3, 0], [3, 3], [3, 5], [5, 5], [5, 3]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9], [10, 11, 12, 13]], convexity = 1); + } + multmatrix([[1, 0, 0, -44], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 5], [2, 5], [2, 6], [6, 6], [6, 5], [7, 5], [7, 3], [3, 3], [3, 2], [6, 2], [6, 1], [3, 4], [3, 5], [5, 5], [5, 4]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], [14, 15, 16, 17]], convexity = 1); + } + multmatrix([[1, 0, 0, -36], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 1], [1, 6], [6, 6], [6, 5], [7, 5], [7, 1], [5, 1], [5, 5], [3, 5], [3, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]], convexity = 1); + } + multmatrix([[1, 0, 0, -28], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[2, 1], [2, 2], [5, 2], [5, 4], [2, 4], [2, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [3, 6], [3, 5], [6, 5], [6, 4], [7, 4], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [5, 5], [5, 6], [3, 6], [3, 2], [5, 2], [5, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 1], [1, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 6], [6, 6], [6, 5], [7, 5], [7, 1], [5, 1], [5, 2], [3, 2], [3, 1], [3, 3], [3, 5], [5, 5], [5, 3]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], [16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, -4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 1], [1, 7], [5, 7], [5, 6], [6, 6], [6, 5], [7, 5], [7, 3], [6, 3], [6, 2], [5, 2], [5, 1], [3, 2], [3, 6], [4, 6], [4, 5], [5, 5], [5, 3], [4, 3], [4, 2]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], [12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = undef, paths = undef, convexity = 1); + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 1], [1, 7], [6, 7], [6, 6], [7, 6], [7, 4], [6, 4], [6, 2], [7, 2], [7, 1], [5, 1], [5, 2], [4, 2], [4, 3], [3, 3], [3, 1], [3, 4], [3, 6], [5, 6], [5, 4]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], [16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 5], [2, 5], [2, 6], [6, 6], [6, 5], [7, 5], [7, 2], [6, 2], [6, 1], [3, 2], [3, 5], [5, 5], [5, 2]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], [12, 13, 14, 15]], convexity = 1); + } + multmatrix([[1, 0, 0, 28], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 5], [2, 5], [2, 6], [6, 6], [6, 5], [3, 5], [3, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + multmatrix([[1, 0, 0, 36], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 1], [1, 7], [3, 7], [3, 4], [4, 4], [4, 5], [6, 5], [6, 4], [5, 4], [5, 3], [6, 3], [6, 2], [7, 2], [7, 1], [5, 1], [5, 2], [4, 2], [4, 3], [3, 3], [3, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, 44], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[1, 1], [1, 2], [5, 2], [5, 3], [2, 3], [2, 4], [1, 4], [1, 5], [2, 5], [2, 6], [7, 6], [7, 5], [3, 5], [3, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); + } + multmatrix([[1, 0, 0, 52], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + polygon(points = [[3, 1], [3, 2], [5, 2], [5, 1], [3, 3], [3, 7], [5, 7], [5, 3]], paths = [[0, 1, 2, 3], [4, 5, 6, 7]], convexity = 1); + } + } + group() { + multmatrix([[1, 0, 0, -24], [0, 1, 0, -8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + group() { + union() { + group() { + hull() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + union() { + group() { + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, -16], [0, 1, 0, -8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + group() { + union() { + group() { + hull() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + union() { + group() { + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + union() { + group() { + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, -8], [0, 1, 0, -8], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + group() { + union() { + group() { + hull() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 1], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 1], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + hull() { + multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { + circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); + } + } + } + } + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, -16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + group() { + union() { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + group() { + group() { + multmatrix([[1, 0, 0, 0.25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 1.53081e-17], [0, 1, 0, 0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.25], [0, 1, 0, 3.06162e-17], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -4.59243e-17], [0, 1, 0, -0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); + } + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 8], [0, 1, 0, -16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + group() { + union() { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + group() { + group() { + multmatrix([[1, 0, 0, 0.25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 1.53081e-17], [0, 1, 0, 0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.25], [0, 1, 0, 3.06162e-17], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -4.59243e-17], [0, 1, 0, -0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); + } + } + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, 16], [0, 1, 0, -16], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + group() { + union() { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + group() { + group() { + multmatrix([[1, 0, 0, 0.25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 1.53081e-17], [0, 1, 0, 0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.25], [0, 1, 0, 3.06162e-17], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, -4.59243e-17], [0, 1, 0, -0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + group() { + multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + group() { + polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); + } + } + } + } + } + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/text-search-test-expected.txt b/tests/regression/dumptest/text-search-test-expected.txt deleted file mode 100644 index f0c8aad..0000000 --- a/tests/regression/dumptest/text-search-test-expected.txt +++ /dev/null @@ -1,848 +0,0 @@ - group(); - group() { - multmatrix([[1, 0, 0, -60], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 2], [6, 2], [6, 1], [3, 2], [3, 6], [5, 6], [5, 2]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], [12, 13, 14, 15]], convexity = 1); - } - multmatrix([[1, 0, 0, -52], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 0], [1, 6], [6, 6], [6, 5], [7, 5], [7, 3], [6, 3], [6, 2], [3, 2], [3, 0], [3, 3], [3, 5], [5, 5], [5, 3]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9], [10, 11, 12, 13]], convexity = 1); - } - multmatrix([[1, 0, 0, -44], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 5], [2, 5], [2, 6], [6, 6], [6, 5], [7, 5], [7, 3], [3, 3], [3, 2], [6, 2], [6, 1], [3, 4], [3, 5], [5, 5], [5, 4]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], [14, 15, 16, 17]], convexity = 1); - } - multmatrix([[1, 0, 0, -36], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 1], [1, 6], [6, 6], [6, 5], [7, 5], [7, 1], [5, 1], [5, 5], [3, 5], [3, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]], convexity = 1); - } - multmatrix([[1, 0, 0, -28], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[2, 1], [2, 2], [5, 2], [5, 4], [2, 4], [2, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [3, 6], [3, 5], [6, 5], [6, 4], [7, 4], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, -20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [5, 5], [5, 6], [3, 6], [3, 2], [5, 2], [5, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 1], [1, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 6], [6, 6], [6, 5], [7, 5], [7, 1], [5, 1], [5, 2], [3, 2], [3, 1], [3, 3], [3, 5], [5, 5], [5, 3]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], [16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, -4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 1], [1, 7], [5, 7], [5, 6], [6, 6], [6, 5], [7, 5], [7, 3], [6, 3], [6, 2], [5, 2], [5, 1], [3, 2], [3, 6], [4, 6], [4, 5], [5, 5], [5, 3], [4, 3], [4, 2]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], [12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = undef, paths = undef, convexity = 1); - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 1], [1, 7], [6, 7], [6, 6], [7, 6], [7, 4], [6, 4], [6, 2], [7, 2], [7, 1], [5, 1], [5, 2], [4, 2], [4, 3], [3, 3], [3, 1], [3, 4], [3, 6], [5, 6], [5, 4]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15], [16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 5], [2, 5], [2, 6], [6, 6], [6, 5], [7, 5], [7, 2], [6, 2], [6, 1], [3, 2], [3, 5], [5, 5], [5, 2]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], [12, 13, 14, 15]], convexity = 1); - } - multmatrix([[1, 0, 0, 28], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 5], [2, 5], [2, 6], [6, 6], [6, 5], [3, 5], [3, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - multmatrix([[1, 0, 0, 36], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 1], [1, 7], [3, 7], [3, 4], [4, 4], [4, 5], [6, 5], [6, 4], [5, 4], [5, 3], [6, 3], [6, 2], [7, 2], [7, 1], [5, 1], [5, 2], [4, 2], [4, 3], [3, 3], [3, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, 44], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[1, 1], [1, 2], [5, 2], [5, 3], [2, 3], [2, 4], [1, 4], [1, 5], [2, 5], [2, 6], [7, 6], [7, 5], [3, 5], [3, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19]], convexity = 1); - } - multmatrix([[1, 0, 0, 52], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - polygon(points = [[3, 1], [3, 2], [5, 2], [5, 1], [3, 3], [3, 7], [5, 7], [5, 3]], paths = [[0, 1, 2, 3], [4, 5, 6, 7]], convexity = 1); - } - } - group() { - multmatrix([[1, 0, 0, -24], [0, 1, 0, -8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - group() { - union() { - group() { - hull() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - union() { - group() { - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, -16], [0, 1, 0, -8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - group() { - union() { - group() { - hull() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - union() { - group() { - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - union() { - group() { - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, -8], [0, 1, 0, -8], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - group() { - union() { - group() { - hull() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 1], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 1], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 7], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 5], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 3], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 5], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 3], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 7], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - hull() { - multmatrix([[1, 0, 0, 6], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, 1], [0, 0, 1, 0], [0, 0, 0, 1]]) { - circle($fn = 8, $fa = 12, $fs = 2, r = 0.125); - } - } - } - } - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, -16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - group() { - union() { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - group() { - group() { - multmatrix([[1, 0, 0, 0.25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 1.53081e-17], [0, 1, 0, 0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.25], [0, 1, 0, 3.06162e-17], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -4.59243e-17], [0, 1, 0, -0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [3, 2], [3, 5], [2, 5], [2, 6], [3, 6], [3, 7], [5, 7], [5, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]], convexity = 1); - } - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 8], [0, 1, 0, -16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - group() { - union() { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - group() { - group() { - multmatrix([[1, 0, 0, 0.25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 1.53081e-17], [0, 1, 0, 0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.25], [0, 1, 0, 3.06162e-17], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -4.59243e-17], [0, 1, 0, -0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[1, 1], [1, 2], [2, 2], [2, 3], [3, 3], [3, 4], [4, 4], [4, 5], [5, 5], [5, 6], [3, 6], [3, 5], [1, 5], [1, 6], [2, 6], [2, 7], [6, 7], [6, 6], [7, 6], [7, 5], [6, 5], [6, 4], [5, 4], [5, 3], [4, 3], [4, 2], [3, 2], [7, 2], [7, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28]], convexity = 1); - } - } - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, 16], [0, 1, 0, -16], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - group() { - union() { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - group() { - group() { - multmatrix([[1, 0, 0, 0.25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 1.53081e-17], [0, 1, 0, 0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, 0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.25], [0, 1, 0, 3.06162e-17], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, -4.59243e-17], [0, 1, 0, -0.25], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - group() { - multmatrix([[1, 0, 0, 0.176777], [0, 1, 0, -0.176777], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - group() { - polygon(points = [[2, 1], [2, 2], [1, 2], [1, 3], [3, 3], [3, 2], [5, 2], [5, 3], [4, 3], [4, 4], [3, 4], [3, 5], [4, 5], [4, 6], [1, 6], [1, 7], [7, 7], [7, 6], [6, 6], [6, 5], [5, 5], [5, 4], [6, 4], [6, 3], [7, 3], [7, 2], [6, 2], [6, 1]], paths = [[0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27]], convexity = 1); - } - } - } - } - } - } - } - } - } - } - } - diff --git a/tests/regression/dumptest/transform-tests-expected.csg b/tests/regression/dumptest/transform-tests-expected.csg new file mode 100644 index 0000000..892af51 --- /dev/null +++ b/tests/regression/dumptest/transform-tests-expected.csg @@ -0,0 +1,45 @@ +group() { + multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 2, 0, 0], [0, 0, 0.5, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } + } + multmatrix([[1, 0, 0, 20], [0, 1, 0, -30], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[0.5, 0, 0, 0], [0, 0.5, 0, 0], [0, 0, 0.5, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -20], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 2.22045e-16, -1, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -40], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[0.707107, -1.11022e-16, 0.707107, 0], [0.707107, 2.22045e-16, -0.707107, 0], [0, 1, 3.33067e-16, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 0.707107, 0.707107, 0], [0, -0.707107, 0.707107, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } + multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } + multmatrix([[1, 0.4, 0.1, -25], [0.4, 0.8, 0, -25], [0.2, 0.2, 0.5, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); + } + } +} diff --git a/tests/regression/dumptest/transform-tests-expected.txt b/tests/regression/dumptest/transform-tests-expected.txt deleted file mode 100644 index 97657da..0000000 --- a/tests/regression/dumptest/transform-tests-expected.txt +++ /dev/null @@ -1,44 +0,0 @@ - multmatrix([[1, 0, 0, 25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 2, 0, 0], [0, 0, 0.5, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - } - multmatrix([[1, 0, 0, 20], [0, 1, 0, -30], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[0.5, 0, 0, 0], [0, 0.5, 0, 0], [0, 0, 0.5, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -20], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 2.22045e-16, -1, 0], [0, 1, 2.22045e-16, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -40], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[0.707107, -1.11022e-16, 0.707107, 0], [0.707107, 2.22045e-16, -0.707107, 0], [0, 1, 3.33067e-16, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 0.707107, 0.707107, 0], [0, -0.707107, 0.707107, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - multmatrix([[1, 0, 0, -25], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - multmatrix([[1, 0.4, 0.1, -25], [0.4, 0.8, 0, -25], [0.2, 0.2, 0.5, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 1, h = 20, r1 = 10, r2 = 0, center = false); - } - } - diff --git a/tests/regression/dumptest/translate-expected.csg b/tests/regression/dumptest/translate-expected.csg new file mode 100644 index 0000000..87e28e2 --- /dev/null +++ b/tests/regression/dumptest/translate-expected.csg @@ -0,0 +1,3 @@ +group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); +} diff --git a/tests/regression/dumptest/translate-expected.txt b/tests/regression/dumptest/translate-expected.txt deleted file mode 100644 index c3185a3..0000000 --- a/tests/regression/dumptest/translate-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - diff --git a/tests/regression/dumptest/union-expected.csg b/tests/regression/dumptest/union-expected.csg new file mode 100644 index 0000000..34f53c2 --- /dev/null +++ b/tests/regression/dumptest/union-expected.csg @@ -0,0 +1,3 @@ +group() { + union(); +} diff --git a/tests/regression/dumptest/union-expected.txt b/tests/regression/dumptest/union-expected.txt deleted file mode 100644 index 654849e..0000000 --- a/tests/regression/dumptest/union-expected.txt +++ /dev/null @@ -1,2 +0,0 @@ - union(); - diff --git a/tests/regression/dumptest/union-tests-expected.csg b/tests/regression/dumptest/union-tests-expected.csg new file mode 100644 index 0000000..064fbe2 --- /dev/null +++ b/tests/regression/dumptest/union-tests-expected.csg @@ -0,0 +1,48 @@ +group() { + multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [10, 10, 10], center = false); + multmatrix([[1, 0, 0, 4], [0, 1, 0, 4], [0, 0, 1, 8], [0, 0, 0, 1]]) { + cube(size = [2, 2, 10], center = false); + } + } + } + union() { + cube(size = [10, 10, 10], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [2, 2, 10], center = false); + } + } + multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [10, 10, 10], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11], [0, 0, 0, 1]]) { + cube(size = [2, 2, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [10, 10, 10], center = false); + multmatrix([[1, 0, 0, 4], [0, 1, 0, 4], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [2, 2, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, -12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [10, 10, 10], center = false); + multmatrix([[1, 0, 0, -2], [0, 1, 0, 10], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [2, 2, 10], center = false); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + cube(size = [10, 10, 10], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 10], [0, 0, 0, 1]]) { + cube(size = [2, 2, 10], center = false); + } + } + } +} diff --git a/tests/regression/dumptest/union-tests-expected.txt b/tests/regression/dumptest/union-tests-expected.txt deleted file mode 100644 index b0a30f6..0000000 --- a/tests/regression/dumptest/union-tests-expected.txt +++ /dev/null @@ -1,47 +0,0 @@ - multmatrix([[1, 0, 0, -12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [10, 10, 10], center = false); - multmatrix([[1, 0, 0, 4], [0, 1, 0, 4], [0, 0, 1, 8], [0, 0, 0, 1]]) { - cube(size = [2, 2, 10], center = false); - } - } - } - union() { - cube(size = [10, 10, 10], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [2, 2, 10], center = false); - } - } - multmatrix([[1, 0, 0, 12], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [10, 10, 10], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 11], [0, 0, 0, 1]]) { - cube(size = [2, 2, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, 24], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [10, 10, 10], center = false); - multmatrix([[1, 0, 0, 4], [0, 1, 0, 4], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [2, 2, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, -12], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [10, 10, 10], center = false); - multmatrix([[1, 0, 0, -2], [0, 1, 0, 10], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [2, 2, 10], center = false); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 12], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - cube(size = [10, 10, 10], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, 10], [0, 0, 1, 10], [0, 0, 0, 1]]) { - cube(size = [2, 2, 10], center = false); - } - } - } - diff --git a/tests/regression/dumptest/use-tests-expected.csg b/tests/regression/dumptest/use-tests-expected.csg new file mode 100644 index 0000000..c47fa74 --- /dev/null +++ b/tests/regression/dumptest/use-tests-expected.csg @@ -0,0 +1,102 @@ +group() { + group() { + group() { + multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0.7, r2 = 0.2, center = true); + } + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cylinder($fn = 10, $fa = 12, $fs = 2, h = 1, r1 = 0.5, r2 = 0.5, center = true); + } + } + cube(size = [1, 1, 1], center = true); + } + multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, 4], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]); + multmatrix([[1, 0, 0, -2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); + } + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + difference() { + cube(size = [1, 1, 1], center = true); + cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 0.4, r2 = 0.4, center = true); + } + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + cube(size = [0.5, 0.5, 1], center = true); + } + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { + sphere($fn = 16, $fa = 12, $fs = 2, r = 1); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) { + union() { + linear_extrude(height = 1.5, center = true, convexity = 1, twist = 0, slices = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + circle($fn = 30, $fa = 12, $fs = 2, r = 0.3); + } + linear_extrude(height = 1.5, center = true, convexity = 1, twist = 0, slices = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + projection(cut = false, convexity = 0) { + multmatrix([[0, 0, -1, 0], [0, 1, 0, 0], [1, 0, 0, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.31819805153], [0, 0, 0, 1]]) { + cylinder($fn = 30, $fa = 12, $fs = 2, h = 0.212132, r1 = 0.212132, r2 = 0, center = true); + } + } + } + } + } + } + } + } + multmatrix([[1, 0, 0, -2], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [1.43239, 0.5, 0.5], center = true); + } + multmatrix([[1, 0, 0, 2], [0, 1, 0, -4], [0, 0, 1, -0.5], [0, 0, 0, 1]]) { + multmatrix([[0.05, 0, 0, 0], [0, 0.05, 0, 0], [0, 0, 0.05, 0], [0, 0, 0, 1]]) { + group() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { + union() { + multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 17], [0, 0, 0, 1]]) { + cylinder($fn = 30, $fa = 12, $fs = 2, h = 8, r1 = 6, r2 = 6, center = false); + cylinder($fn = 20, $fa = 12, $fs = 2, h = 10.5, r1 = 2.5, r2 = 2.5, center = false); + } + multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { + cube(size = [12, 22.8, 19.5], center = false); + multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 17], [0, 0, 0, 1]]) { + cube(size = [12, 7, 2.5], center = false); + } + multmatrix([[1, 0, 0, 0], [0, 1, 0, 20.8], [0, 0, 1, 17], [0, 0, 0, 1]]) { + cube(size = [12, 7, 2.5], center = false); + } + } + group(); + multmatrix([[1, 0, 0, -6], [0, 1, 0, 0], [0, 0, 1, 19], [0, 0, 0, 1]]) { + multmatrix([[0, 0, 1, 0], [1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) { + group() { + linear_extrude(height = 12, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { + polygon(points = [[0, 0], [18, 0], [0, 4]], paths = [[0, 1, 2]], convexity = 1); + } + } + } + } + multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 19], [0, 0, 0, 1]]) { + cube(size = [12, 6.5, 4], center = false); + } + } + group(); + } + } + } + } + } + } +} diff --git a/tests/regression/dumptest/use-tests-expected.txt b/tests/regression/dumptest/use-tests-expected.txt deleted file mode 100644 index 1095708..0000000 --- a/tests/regression/dumptest/use-tests-expected.txt +++ /dev/null @@ -1,101 +0,0 @@ - group() { - group() { - multmatrix([[1, 0, 0, 2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 0, $fa = 12, $fs = 2, h = 1, r1 = 0.7, r2 = 0.2, center = true); - } - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cylinder($fn = 10, $fa = 12, $fs = 2, h = 1, r1 = 0.5, r2 = 0.5, center = true); - } - } - cube(size = [1, 1, 1], center = true); - } - multmatrix([[1, 0, 0, 4], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, 4], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]); - multmatrix([[1, 0, 0, -2], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - sphere($fn = 8, $fa = 12, $fs = 2, r = 0.5); - } - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - difference() { - cube(size = [1, 1, 1], center = true); - cylinder($fn = 0, $fa = 12, $fs = 2, h = 2, r1 = 0.4, r2 = 0.4, center = true); - } - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - cube(size = [0.5, 0.5, 1], center = true); - } - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -2], [0, 0, 1, 0], [0, 0, 0, 1]]) { - sphere($fn = 16, $fa = 12, $fs = 2, r = 1); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[0, 0, 1, 0], [0, 1, 0, 0], [-1, 0, 0, 0], [0, 0, 0, 1]]) { - union() { - linear_extrude(height = 1.5, center = true, convexity = 1, twist = 0, slices = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - circle($fn = 30, $fa = 12, $fs = 2, r = 0.3); - } - linear_extrude(height = 1.5, center = true, convexity = 1, twist = 0, slices = 2, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - projection(cut = false, convexity = 0) { - multmatrix([[0, 0, -1, 0], [0, 1, 0, 0], [1, 0, 0, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0.31819805153], [0, 0, 0, 1]]) { - cylinder($fn = 30, $fa = 12, $fs = 2, h = 0.212132, r1 = 0.212132, r2 = 0, center = true); - } - } - } - } - } - } - } - } - multmatrix([[1, 0, 0, -2], [0, 1, 0, -4], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [1.43239, 0.5, 0.5], center = true); - } - multmatrix([[1, 0, 0, 2], [0, 1, 0, -4], [0, 0, 1, -0.5], [0, 0, 0, 1]]) { - multmatrix([[0.05, 0, 0, 0], [0, 0.05, 0, 0], [0, 0, 0.05, 0], [0, 0, 0, 1]]) { - group() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 0], [0, 0, 0, 1]]) { - union() { - multmatrix([[1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 1, 17], [0, 0, 0, 1]]) { - cylinder($fn = 30, $fa = 12, $fs = 2, h = 8, r1 = 6, r2 = 6, center = false); - cylinder($fn = 20, $fa = 12, $fs = 2, h = 10.5, r1 = 2.5, r2 = 2.5, center = false); - } - multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 0], [0, 0, 0, 1]]) { - cube(size = [12, 22.8, 19.5], center = false); - multmatrix([[1, 0, 0, 0], [0, 1, 0, -5], [0, 0, 1, 17], [0, 0, 0, 1]]) { - cube(size = [12, 7, 2.5], center = false); - } - multmatrix([[1, 0, 0, 0], [0, 1, 0, 20.8], [0, 0, 1, 17], [0, 0, 0, 1]]) { - cube(size = [12, 7, 2.5], center = false); - } - } - group(); - multmatrix([[1, 0, 0, -6], [0, 1, 0, 0], [0, 0, 1, 19], [0, 0, 0, 1]]) { - multmatrix([[0, 0, 1, 0], [1, 0, 0, 0], [0, 1, 0, 0], [0, 0, 0, 1]]) { - group() { - linear_extrude(height = 12, center = false, convexity = 1, scale = [1, 1], $fn = 0, $fa = 12, $fs = 2) { - polygon(points = [[0, 0], [18, 0], [0, 4]], paths = [[0, 1, 2]], convexity = 1); - } - } - } - } - multmatrix([[1, 0, 0, -6], [0, 1, 0, -6], [0, 0, 1, 19], [0, 0, 0, 1]]) { - cube(size = [12, 6.5, 4], center = false); - } - } - group(); - } - } - } - } - } - } - -- cgit v0.10.1