Orient all prims in the same direction
1543 3 2- badman
- Member
- 11 posts
- Joined: 12月 2016
- Offline
I can't orient all these prims upwards no matter what I try. I understand it's because of the vertex order but I don't know of any way to give all input prims the same vertex order (e.g. all clockwise/counterclockwise). I've tried methods with Clean, PolyDoctor, Primitive, Sort, even forcing assignment of up, N, and orient with attribwrangle but nothing works.
Edited by badman - 2023年2月2日 17:39:09
- toadstorm
- Member
- 377 posts
- Joined: 4月 2017
- Offline
There's probably a few ways to go about this, but what you want to do is use a Reverse SOP on any prims that are pointing the wrong way.
Assuming there's only two directions your shells could be pointing (up or down), all you need to do is group any prims that are facing towards -Y. Use a Group Create SOP, enable Keep by Normals, then set Direction to 0,1,0 (or 0,-1,0) and reduce the Spread Angle until you've isolated only the prims facing the wrong direction. Then Reverse that group.
Assuming there's only two directions your shells could be pointing (up or down), all you need to do is group any prims that are facing towards -Y. Use a Group Create SOP, enable Keep by Normals, then set Direction to 0,1,0 (or 0,-1,0) and reduce the Spread Angle until you've isolated only the prims facing the wrong direction. Then Reverse that group.
MOPs (Motion Operators for Houdini): http://www.motionoperators.com [www.motionoperators.com]
- badman
- Member
- 11 posts
- Joined: 12月 2016
- Offline
- toadstorm
- Member
- 377 posts
- Joined: 4月 2017
- Offline
Primitive normals are determined by the winding order of the vertices that make up each primitive... they're not an attribute in the usual sense. The Reverse SOP flips that order so the implicit primitive normal also flips.
MOPs (Motion Operators for Houdini): http://www.motionoperators.com [www.motionoperators.com]
-
- Quick Links