Created
November 24, 2019 10:19
-
-
Save thehans/b7729a1830ae4dd8c89ef450bfe44aa3 to your computer and use it in GitHub Desktop.
OpenSCAD example for rotating about arbitrary pivot point
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module rotate_about(a, v, p=[0,0,0]) { | |
translate(p) rotate(a,v) translate(-p) children(); | |
} | |
// example usage | |
rotate_about([0,45,0],p=[5,0,10]) | |
cylinder(r=5,h=10); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment