chiark / gitweb /
sewing-table: fold in InterlockLobeCore (nfc)
[reprap-play.git] / sewing-table.scad.m4
index 9880e2bae0dc6fabbb5554b9da67ced22880121a..dc94aae3cce1ecc718120db6b3b03b46fa6f3f0e 100644 (file)
@@ -139,10 +139,15 @@ module InterlockLobePlan(r, ymir) {
   }
 }
 
-module InterlockLobeCore(negative=0) {
+module InterlockEdge(left_cnr, right_cnr, negative=0, nlobes=2) {
   r = negative ? interlock_negative_rad : interlock_rad;
   plusth = negative * 1.0;
   ymir = negative ? 0 : 1;
+
+  INREFFRAME(left_cnr, right_cnr) {
+    for (lobei = [ 0 : nlobes-1 ]) {
+      lobex = (length - thehd[0]*2) * (lobei ? lobei / (nlobes-1) : 0);
+      translate([lobex, 0, 0]) {
   translate([0, 0, plusth]){
     mirror([0,0,1]){
       linear_extrude(height=tile_th+plusth*2, convexity=10){
@@ -150,14 +155,7 @@ module InterlockLobeCore(negative=0) {
       }
     }
   }
-}
-
-module InterlockEdge(left_cnr, right_cnr, negative=0, nlobes=2) {
-  INREFFRAME(left_cnr, right_cnr) {
-    for (lobei = [ 0 : nlobes-1 ]) {
-      lobex = (length - thehd[0]*2) * (lobei ? lobei / (nlobes-1) : 0);
-      translate([lobex, 0, 0])
-       InterlockLobeCore(negative);
+      }
     }
   }
 }