chiark / gitweb /
commitid-layering-test: move cylinder out of Body() (nfc)
[reprap-play.git] / commitid-layering-test.scad
index 0e0ea51c4ae0d6133fb2f337209d9a60af07f489..c988c98443be1ea480f169938bb98e843c820aad 100644 (file)
@@ -2,14 +2,28 @@
 
 include <commitid.scad>
 
-baseh= 2;
+baseh= 1;
+basex = 31;
+basey= 20;
+basexpos = -12;
+baseypos = -4;
 
-mirror([0,0,1])
-  translate([-8,-2, -0.01])
-  cube([17.5,10, baseh + 0.01]);
+module Body(){
+  mirror([0,0,1])
+    translate([basexpos, baseypos])
+    cube([basex, basey, baseh]);
+}
 
-linear_extrude(height= 0.4 + 0.1)
-  Commitid_FontDemo();
+difference(){
+  Body();
+  translate([basex + basexpos, basey + baseypos, -baseh])
+    rotate([0,0,180])
+    Commitid_BestCount([basex,basey], margin=3);
+}
 
-translate([-4,3,0])
-cylinder(r=3, h=3);
+translate([-6, 6, 0])
+  cylinder(r=4, h=3, $fn=20);
+
+echo("pause height (mm)", baseh+0.01);
+
+Commitid_FontDemo();