Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions regular_shapes.scad
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,21 @@ module ellipse(width, height) {
scale([1, height/width, 1]) circle(r=width/2);
}

module pointed_ellipse(width, length, height) {
width_ratio = (width/2)/width;
original_length = (width*2) * sqrt(3);
length_ratio = length/original_length;

translate([-(width/2),0,0])
scale([width_ratio,length_ratio,1]) {
intersection() {
cylinder(r=width*2,h=height,center=true);
translate([width*2,0,0])
cylinder(r=width*2,h=height,center=true);
}
}
}

// The ratio of lenght and width is about 1.39 for a real egg
module egg_outline(width, length){
translate([0, width/2, 0]) union(){
Expand Down