Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Way to round edges of objects opensCAD

Tags:

openscad

Is there an easy way/function to round edges for an openscad object?

e.g. round the edges of the cylinders

like image 568
Matthias Adriaens Avatar asked Oct 15 '15 11:10

Matthias Adriaens


2 Answers

There are probably many ways to make a rounded cylinder. One way is to make 2 donut shaped objects and hull them

hull(){
rotate_extrude() translate([r1,0,0]) circle(r2);
rotate_extrude() translate([r1,0,h1]) circle(r2);
}
like image 142
Don Avatar answered Oct 05 '22 21:10

Don


minkowski() is your friend for rounding over all edges of a geometry. minkowski() is also incredibly slow and should only be used for final rendering. You can also implement primitives which have rounded edges more efficiently with other constructs.

$fn=60;

module drawLedgeRing()
{
    difference()
    {
        cylinder(4,10,10);

        translate([0,0,-1])
        cylinder(4,6,6);

        translate([0,0,2])
        cylinder(4,8,8);
    }
}

minkowski()
{
    drawLedgeRing();
    sphere(.25);
}

//drawLedgeRing();
like image 41
Scott Leslie Avatar answered Oct 05 '22 20:10

Scott Leslie