Skip to content
Snippets Groups Projects
Commit 1bc154b3 authored by fxk8y's avatar fxk8y :spider:
Browse files

Reordering modules

parent 138f62e0
No related branches found
No related tags found
No related merge requests found
/**
*
* TODO: Moar documentation!
*
*/
module roundRect(w, h, r) {
if (r > 0) {
_dw2 = (w - 2*r) / 2;
_dh2 = (h - 2*r) / 2;
hull() for (tx=[-_dw2, _dw2], ty=[-_dh2, _dh2]) translate([tx, ty, 0]) circle(r=r);
} else {
square([w, h], center=true);
}
}
/**
* A round triangle pointing along the X-Axis
......@@ -37,3 +21,19 @@ module roundTri(w, h, r, style="inner") {
}
}
/**
*
* TODO: Moar documentation!
*
*/
module roundRect(w, h, r) {
if (r > 0) {
_dw2 = (w - 2*r) / 2;
_dh2 = (h - 2*r) / 2;
hull() for (tx=[-_dw2, _dw2], ty=[-_dh2, _dh2]) translate([tx, ty, 0]) circle(r=r);
} else {
square([w, h], center=true);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment