From 997a032370616a432f0cdd397ba20a1f93982f78 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gy=C3=B6rgy=20Kurucz?= <gyuri@sajt.pw> Date: Fri, 26 Jul 2019 14:34:09 +0200 Subject: [PATCH] Add file with many abbreviated commands. --- include/short.scad | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 include/short.scad diff --git a/include/short.scad b/include/short.scad new file mode 100644 index 0000000..508c750 --- /dev/null +++ b/include/short.scad @@ -0,0 +1,27 @@ +module tX(x) { translate([x,0,0]) children(); } +module tY(y) { translate([0,y,0]) children(); } +module tZ(z) { translate([0,0,z]) children(); } +module tXY(x,y) { translate([x,y,0]) children(); } +module tXZ(x,z) { translate([x,0,z]) children(); } +module tYZ(y,z) { translate([0,y,z]) children(); } +module tXYZ(x,y,z) { translate([x,y,z]) children(); } + +module rX(x) { rotate([x,0,0]) children(); } +module rY(y) { rotate([0,y,0]) children(); } +module rZ(z) { rotate([0,0,z]) children(); } + +// operations +module diff() { + difference() { + children(0); + // step needed in case $children < 2 + for (i=[1:1:$children-1]) children(i); + } +} + +module tube(l, th) { + linear_extrude(l) diff() { + offset(2*th) children(); + children(); + } +} -- GitLab