rotate object given center and degrees

Cory’s solution works if you want to rotate all the points in your mesh by the same angle, but from the description, it sounds like you have a different rotation for each point (so that you can condense the x,y pair with a single rotation value). You can convert the rotation (and height along z) to an x,y,z position using the Calculator filter. When you create the Calculator, also turn on the Coordinate Results so that the position of each point gets set to the result. The expression will look something like this.

(cos(degrees * 3.14159/180) + x_center)*iHat + (sin(degrees * 3.14159/180) + y_center)*jHat + height*kHat

In the expression above, replace degrees with the field that specifies the rotation for each point in the 3D mesh. Replace x_center and y_center with the x,y center you said you have. Replace height with the z position of each point. (You didn’t say you had a z position, but you said it is a 3D mesh, so you must have it.)

As Cory suggested, you should also be able to do this with the Python Calculator and it would probably be faster, but I find the regular Calculator easier to use.

1 Like