breadbox Posted April 13, 2014 Share Posted April 13, 2014 (edited) I'm not sure how to put together a matrix to rotate a normal. I would like to do 2 different types of rotation operations. I would like to do these in VOP SOPs or wrangles so they can be easily and quickly used in copy sops to drive clones. The first would be spin along the normal. so if you can imagine a football thrown through the air.. the trajectory is pointing towards the goal, but it needs to spin around.(z spin) The second rotate operation would be the cross product of this, so now the football will be thrown badly and it will spin perpendicular to the direction of travel (x spin). my attempt is attached. I tried to calculate the normal in a attribute and then use that as the axis parameter in a rotate vop. It looks like its "almost" working. at certain rotation angles there is a pretty severe skew that happens to the copied object. as well the rotation is not smooth, its kind of choppy, not right. Its also significant that the vector I want to rotate around will be different "for each" point. using an up vector it seems to work, but not a custom vector angle per point. rotate_vector_ODFORCE_V1.hipnc Edited April 13, 2014 by breadbox Quote Link to comment Share on other sites More sharing options...
petz Posted April 13, 2014 Share Posted April 13, 2014 i didn´t look at your file but in the link below you can find some examples how to rotate normals... http://forums.odforce.net/topic/11404-calculating-a-rotational-matrix/ hth. petz 1 Quote Link to comment Share on other sites More sharing options...
breadbox Posted April 14, 2014 Author Share Posted April 14, 2014 great. That's an interesting thread with examples. I think the answer is there. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.