rotate()

The rotate modifier will rotate the children of the modifier. It will rotate all the children around the Z-Axis at the origin.

Start by adding a cube.

cube()

render the cube ( press f5 )

add the rotate transformation and render the model ( press f5 )

rotate(10)
cube();

The cube has rotated in the clockwise direction by 10 degrees.

If you need to rotate the cube about its center, first center the cube then rotate.

rotate(10)
cube( center = true );

You can rotate around any axis by providing a vector. Add

rotate([30,0,0])
cube();

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: