Hey guys. This code works perfectly for transform the packed geo to origin(0,0,0). I'm having difficulty transforming it back. What would be the code? Thanks.
matrix3 newRot = ident();
matrix myMatrix = primintrinsic(0, "packedfulltransform", 0);
setprimintrinsic(0, "transform", @ptnum, newRot, "set");
v@P *= invert(myMatrix);
transform packed geo to origin and back
1185 2 1- nelpiper73
- Member
- 69 posts
- Joined: May 2017
- Offline
- toadstorm
- Member
- 359 posts
- Joined: April 2017
- Offline
assuming you still have the original P position and transform from before:
setprimintrinsic(0, "transform", @ptnum, origPackedFullTransform);
@P = origP;
you can't write directly to packedfulltransform as far as i know, but writing to the transform intrinsic should get you what you want in almost any case.
setprimintrinsic(0, "transform", @ptnum, origPackedFullTransform);
@P = origP;
you can't write directly to packedfulltransform as far as i know, but writing to the transform intrinsic should get you what you want in almost any case.
MOPs (Motion Operators for Houdini): http://www.motionoperators.com [www.motionoperators.com]
- nelpiper73
- Member
- 69 posts
- Joined: May 2017
- Offline
-
- Quick Links