With the new coordination system learning I am trying to figure out how to correctly rotate a cylinder to cut out wholes on the side of a upright cylinder.
Say I want to cut wholes in my hollowed out cylinder that is upright must I rotate around the x or z to make the whole cylinder horizontal left to right or the x axis?
And for instance I need to cut front and bck wholes on the y axis so the cylinder is laying front to back or back to front so the cylinder head faces me and the other side faces away from me. Sorry it sounds trivial but struggling to get my head around it.
Thank you.
Sent from Mail for Windows
In the first case, you want to rotate around the y axis.
On Thu, Mar 3, 2022 at 2:33 PM Hendrik blindguydiy@gmail.com wrote:
Hi
With the new coordination system learning I am trying to figure out how to
correctly rotate a cylinder to cut out wholes on the side of a upright
cylinder.
Say I want to cut wholes in my hollowed out cylinder that is upright must
I rotate around the x or z to make the whole cylinder horizontal left to
right or the x axis?
And for instance I need to cut front and bck wholes on the y axis so the
cylinder is laying front to back or back to front so the cylinder head
faces me and the other side faces away from me. Sorry it sounds trivial
but struggling to get my head around it.
Thank you.
Sent from Mail https://go.microsoft.com/fwlink/?LinkId=550986 for
Windows
OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org
On 3/3/2022 12:33 PM, Hendrik wrote:
With the new coordination system learning I am trying to figure out
how to correctly rotate a cylinder to cut out wholes on the side of a
upright cylinder.
You'll have a vertical cylinder, and then you'll want to subtract a
horizontal cylinder. To get a horizontal cylinder you can rotate around
either the X axis (yields a cylinder along the Y axis), or around the Y
axis (yields a cylinder along the X axis).
Let's say that you want a 10-unit-radius cylinder that's 40 units tall,
and you want to cut out a 5-unit-radius hole.
It's simplest if you do this with everything centered on the origin.
More general cases will require translation - if, for instance, you want
to cut two holes.
Here's your base cylinder:
cylinder(h=40, r=10, center=true);
Here's the horizontal cylinder that you want to subtract from it. This
one runs left-right. The height is not important, except that it's got
to be taller than the diameter of the cylinder you're subtracting from.
rotate([0,90,0]) cylinder(h=20, r=5, center=true);
and here's subtracting them:
difference() {
cylinder(h=40, r=10, center=true);
rotate([0,90,0]) cylinder(h=20, r=5, center=true);
}