3D part design with OpenSCAD#125: multiple export files from a single design.

2 min read
By Bob
3D part design with OpenSCAD#125: multiple export files from a single design.

In the last two posts I covered an easy way to split large files into multiple parts with an svg file so they could be printed on a smaller printer and glued together, in this post I'm going to cover a simple "quad" cutter made with only OpenSCAD.

By making 4 separate "cubes" and moving them to different quadrants you can use intersection to cut a design into 4 equal parts:

When you save the file as a .3mf file the slicer will recognize these as separate models, here is an example with Prusa slicer:

Now when you slice the file it will print them out as 4 separate parts:

You can also turn off or on the 4 parts and save them to individual .stl files :

You can manipulate them as separate objects in the slicer software modifying them with different infill, layer heights, colors, etc..which is pretty useful:

Here is the example code:

//

/*[Path to STL] */
 Path_to_STL_File="File.stl";

/*[Quadrant 1] */
show_quadrant1=true;
/*[Quadrant 2] */
show_quadrant2=true;
/*[Quadrant 3] */
show_quadrant3=true;
/*[Quadrant 4] */
show_quadrant4=true;

module quadrant1(){
render()
intersection(){
translate([0,0,-200])
linear_extrude(400)
square(200);
color("red")
import(Path_to_STL_File,center=true);
}}

module quadrant2(){
render()
intersection(){
translate([-200,0,-200])
linear_extrude(400)
square(200);
color("green")
import(Path_to_STL_File,center=true);
}}

module quadrant3(){
render()
intersection(){
translate([-200,-200,-200])
linear_extrude(400)
square(200);
color("dodgerblue")
import(Path_to_STL_File,center=true);
}}

module quadrant4(){
render()
intersection(){
translate([0,-200,-200])
linear_extrude(400)
square(200);
import(Path_to_STL_File,center=true);
}}

if(show_quadrant1)
quadrant1();

if(show_quadrant2)
quadrant2();

if(show_quadrant3)
quadrant3();

if(show_quadrant4)
quadrant4();

As you can see it would be pretty easy to make as many different sections as you want.