OpenSCAD Tutorial
Lesson 2 · Moving, Rotating, and Scaling
Transform order matters
Read a transform chain from the bottom up: the transform closest to the shape happens first.
If you move first and then rotate, the cube swings around the origin like a clock hand, because rotate always turns around the origin.
A good habit: build and rotate a part at the origin first, then translate it into place last.
Your task: the cube below swings away from the X axis. Swap the two transforms so the cube turns 45° in place and then moves to x = 30.
Loading the OpenSCAD editor…
Step 6 of 16