chiark / gitweb /
simplephone-case: wip rounding
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 30 Jun 2017 22:31:09 +0000 (23:31 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Fri, 30 Jun 2017 22:31:09 +0000 (23:31 +0100)
simplephone-case.scad

index fb0f96b85b48daef658f19f53e0ee4511de438ec..caf465e496b3d2a20b80dcb414cc36d5f390f946 100644 (file)
@@ -30,10 +30,31 @@ rail_zsz = 2.5;
 
 case_x_less = 0; //case_x_less = 10;
 
+inner_cnr_rad = 2.0;
+
 // calculated
 
 ym = psz[1]/2;
 
+module RoundedProfile(sz, cnr_rad){
+  hull(){
+    for (x=[ cnr_rad, sz[0]-cnr_rad ])
+      for (y=[ cnr_rad, sz[1]-cnr_rad ])
+       translate([x,y])
+         circle(r= cnr_rad, $fn=20);
+  }
+}
+
+module RoundedCube(sz, cnr_rad){
+  hull(){
+    for (x=[ cnr_rad, sz[0]-cnr_rad ])
+      for (y=[ cnr_rad, sz[1]-cnr_rad ])
+       for (z=[ cnr_rad, sz[2]-cnr_rad ])
+         translate([x,y,z])
+           sphere(r= cnr_rad, $fn=20);
+  }
+}
+
 module Case(){
   difference(){
     mirror([1,0,0])
@@ -84,3 +105,4 @@ module Case(){
 }
 
 Case();
+//RoundedCube(psz, inner_cnr_rad);