I have a complex mesh. I need rotate mesh along some axis (x,y,z never mind) to line-up 2 points of this mesh. I don't need align points (S,Z,0), i need align mesh. Of course i can move pivot to vertex 1 and visually rotate until vertex 2 will be on my desired axe. But i want to keep original pivot and precisely rotate mesh. See the picture.
One simple solution is to create an empty and parent the object to it. Then rotate the empty any way you like. You can easily get the original rotation back by resetting the rotation of the empty.
You can go a tiny bit more complicated by using a Copy Rotation Constraint.
- Create an empty.
- Create a Copy Rotation Constraint on the object to the empty.
- Rotate the empty. Now you can easily switch the constraint on and off, which might be useful for exporting the model to your 3d scanning software for further processing.
TeeTrinker is right: have you tried using the 3D cursor as the "Transform Pivot Point"? Snapping to other geometry does not work in this mode, so if you need absolute precision, I would recommend an add-on like Mesh Align Plus. It has many alignment options, but the one you are looking for in it is "Quick Align Lines". Keep in mind there are far more advanced options that may save you time later on.
Using Mesh Align Plus add-on, here's what I did to achieve the rotation you described:
- Create a new plane mesh object with a side aligned to the final upright green line orientation you showed in your image.
- Select this new plane, entered Edit Mode, select the edge representing the green line, Mesh Align Plus>Quick Align Lines>Grab Destination. Exit Edit Mode.
- Select your plane you want to rotate. Enter Edit mode. Select vertex 1 and vertex 2 like you show in your picture. Exit Edit Mode. Mesh Align Plus>Quick Align Lines>Apply to: "Object".