chiark / gitweb /
commitid-layering-test: make cylinder finer
[reprap-play.git] / commitid-layering-test.scad
index 11260731033407d9847a282f4ec8dbb86495ed29..e9c25b2ca3e98e287ecfdffb7f47075dd8eaeaeb 100644 (file)
@@ -3,14 +3,27 @@
 include <commitid.scad>
 
 baseh= 1;
+basex = 31;
+basey= 20;
+basexpos = -12;
+baseypos = -4;
 
-mirror([0,0,1])
-  translate([-12, -4])
-  cube([31, 20, baseh]);
+module Body(){
+  mirror([0,0,1])
+    translate([basexpos, baseypos])
+    cube([basex, basey, baseh]);
+}
 
-translate([0,0,-0.1])
-linear_extrude(height= Commitid_depth() + 0.1)
-  Commitid_FontDemo_2D();
+difference(){
+  Body();
+  translate([basex + basexpos, basey + baseypos, -baseh])
+    rotate([0,0,180])
+    Commitid_BestCount([basex,basey], margin=3);
+}
 
-translate([-5, 6, 0])
-  cylinder(r=4, h=3, $fn=20);
+translate([-6, 6, 0])
+  cylinder(r=4, h=3, $fn=50);
+
+echo("pause height (mm)", baseh+0.01);
+
+Commitid_FontDemo();