scad: rotate around an arbitrary axis is not supported #32

Closed
tolomea opened this Issue Mar 4, 2012 · 2 comments

Projects

None yet

3 participants

@tolomea

difference() {
sphere(r=25);
rotate(90, [0, 0, 1]) cylinder(r=12.5,h=50,center=true);
rotate(90, [1, 0, 0]) cylinder(r=12.5,h=50,center=true);
rotate(90, [0, 1, 0]) cylinder(r=12.5,h=50,center=true);
}

produces:

Module rotate gave the following warnings:
unused arguments
Module rotate gave the following warnings:
unused arguments
Module rotate gave the following warnings:
unused arguments
Rendering 3D object to bob.stl
DifferenceR3 0.0 [Sphere 25.0,Rotate3 (90.0,0.0,0.0) (Translate3 (0.0,0.0,-25.0) (ExtrudeR 0.0 (Circle 12.5) 50.0)),Rotate3 (90.0,0.0,0.0) (Translate3 (0.0,0.0,-25.0) (ExtrudeR 0.0 (Circle 12.5) 50.0)),Rotate3 (90.0,0.0,0.0) (Translate3 (0.0,0.0,-25.0) (ExtrudeR 0.0 (Circle 12.5) 50.0))]

@tolomea

if you don't have it yet the math for this can be found here: http://en.wikipedia.org/wiki/Rotation_matrix#General_rotations

@shkoo

This should be fixed now with 20a2069

@colah colah closed this Dec 19, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment