khalid Posted July 16, 2016 Share Posted July 16, 2016 Hi everyone I have a scene with packed RBD controlled by a POP ATTRACTOR... i want my objects to be align to the velocity (take the vel vector direction)..i tried to manipulate the orient attr inside the Sop Solver but it didnt works for me or maybe i miss something. Thanks in advance for the help RBD_Orient.hip Quote Link to comment Share on other sites More sharing options...
dchow1992 Posted July 16, 2016 Share Posted July 16, 2016 if you are trying to rotate packed prims you need to modify their intrinsic transform. I provided a possible solution to what you described and another example of rotating packed primitives in the sop network RBD_Orient_2.hipnc 1 Quote Link to comment Share on other sites More sharing options...
khalid Posted July 16, 2016 Author Share Posted July 16, 2016 Hi david COol .... thanks a lot man .. it works great like that ..i tought that to modify the orientation i have to play with the orient attr. Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 16, 2016 Share Posted July 16, 2016 Very cool, David. This was the first major question I had, migrating to Houdini some 1-1/2 years back - and I actually never got it solved, well, not as I would have wanted to solve it. But yeah, this is how I would have wanted to do it. Now, I did a really crappy smooth function using timeshift and a wrangle, but there's just gotta be an easier/better method to do this, right? And over more frames - 5 would do I imagine. Or perhaps there's another way to get rid of the jitter when velocity is really slow? For a moment I started thinking about doing a velocity based multiplier for the alignment, but then I realized I had nothing to multiply, there's no amount of alignment, it's just aligning. packed.align.to.vel.v1.hiplc Quote Link to comment Share on other sites More sharing options...
dchow1992 Posted July 16, 2016 Share Posted July 16, 2016 one thing you could do is interpolate between the new rotation and the rotation from the previous frame, that way you can achieve some sort of blend and that can be based off speed I guess. The jitter is a product of the sharp changes in the velocity and personally I would rather solve that by modifying the forces acting on the points instead of smoothing out the extreme rotations. packed.align.to.vel.v02.hipnc Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 16, 2016 Share Posted July 16, 2016 (edited) Yeah, I played around with forces and drag, trying to balance it out - and sure, it gets better - but smoothing the velocity over three frames makes it a lot calmer, I think upping that to 5 frames would solve the issue completely. I just don't want to have to split it up in two wrangles - or perhaps there's a way to access offset frame attribute values in VEX, though I didn't find anything in the documentation... I just checked your setup, yeah, it's about the same as I get smoothing it over a couple of frames. Here I tweaked drag and forces too... I gotta ask, though, why are you using a multiple solver for the POP forces? As you already have a multiple solver in the RBD solver, they plug right in. And that VOP, damn, following other people's reasoning in VOPs is always a lot of fun... Edited July 16, 2016 by Farmfield 2 Quote Link to comment Share on other sites More sharing options...
dchow1992 Posted July 17, 2016 Share Posted July 17, 2016 (edited) it's mostly just an organizational habit cheers Edited July 17, 2016 by dchow1992 Quote Link to comment Share on other sites More sharing options...
khalid Posted July 17, 2016 Author Share Posted July 17, 2016 wow !! Thanks Guys for your setups Quote Link to comment Share on other sites More sharing options...
Farmfield Posted July 17, 2016 Share Posted July 17, 2016 (edited) 6 hours ago, dchow1992 said: it's mostly just an organizational habit cheers Yeah, I thought that was the likely reason. My mode is almost always to try to minimize the number of nodes, I'm always thinking "how can I simplify this" - because you almost always can. Though I do love to add nulls to keep my node trees looking nice. Sometimes a bit too much. The question is if adding a solver like that will create any overhead or if it's redundancy basically makes it a passthrough. Not really relevant in a setup this small, but doing some 2012 type California is crumbling, falling into the Pacific with a trillion RBD objects stuff like that have a tendency to make a huge difference. And thanks for the scene file, it's a really interesting setup using a slerp to ease out the jitter. I'm at the point where I can understand what a setup like that does, but I've got a bit to go before I can do them myself - sometime, long time in the past, I was supposedly an engineer, hehe, but I'm basically resurrecting my math skills after 20+ years of not really using them, it more or less feels like I'm starting from scratch again. At 45. 4 hours ago, khalid said: wow !! Thanks Guys for your setups Don't thank me, I just took Davids great work into a fitting scene setup to show off how well it worked. All credit goes to him. Edited July 17, 2016 by Farmfield 1 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.