Jump to content

Match Arbritrary Pts To Deform


andrewlowell

Recommended Posts

Ok, does anyone know a simple way I might try and accomplish this. I've done this in the past but with the same exact parent geometry, not deforming. Basically, I've got particles that move around inside of a collider. I'm using the collision goemetry in a dops simulation (squishy object).

I now want to "deform" the particles in the same way that the sphere has been deformed. Kind of like warping their world. Any ideas?

post-3343-1201339656_thumb.jpg

Link to comment
Share on other sites

Ok, here's a system I've got set up so far ... I'm sure you've encountered this issue. The issue is that translating the entire deforming object works really well because I'm calculating the offset based on percentage.

The problem comes about when the deforming object is rotated. The arbitrary object doesn't rotate with it because as some points are say moving up others are moving down and the distance offset is canceling itself out. So, I'm guessing the solution now has to be just about like a skin system, so ... how do you do you own skin system?? I'm guessing it has something to do with normals or rotation maths etc.

Can you (or anyone else) point me in the right direction (not the wrong direction, or a rotated direction :lol: )

Thanks!

(it's the test B object, deformer is animated to rotate)

chop_volume_deform.zip

Edited by andrewlowell
Link to comment
Share on other sites

Actually it looks like making your own skin system in Houdini with CHOPs isn't the hardest task. I just need to get a transform matrix from each point on my point deformer relative to the original points just like how bones work. So, two more questions.

1. If the points have P N and Up attributes, how can I turn this into a transform matrix and ..

2. Does anyone know where I can get a really to the point down to earth resource for really understanding quats, whenever things get tough I always seem to be doing a lot of trail and error with quaternion math, I'd like to understand it better.

I'm using this ..

http://www.gamasutra.com/features/gdcarchive/2000/weber.doc

as a reference, top of page 8

EDIT: ordered learning alg/trig/calc dvd, I will master the quats!! .. still need help getting this into matrix form though.

Edited by andrewlowell
Link to comment
Share on other sites

Wow that looks cool but does it work for 9? I think I had an idea to get it to work in CHOPs, bascially get the distance and percentage to each point on the geometry, then the distance the new volume is offset, then add those values by percentage to the points?

It will compile in H9, and I will post a pre-compiled one once H9 builds start stablising a bit, they change too often at the moment to keep up.

Link to comment
Share on other sites

It will compile in H9, and I will post a pre-compiled one once H9 builds start stablising a bit, they change too often at the moment to keep up.

Thanks if you do I can give it a shot, but I need it to match a certain number of points on the spherical shape, and I'd like a system I can build on. I think if this method works it should be able to deform any shape about any other shape, it just needs one crucial thing which is to work with an entire transform matrix instead of just position.

So, if I have P, N, up ... could this be turned into a transform matrix so I can compute the offset of the deform points relative to the other pts?

Link to comment
Share on other sites

Thanks if you do I can give it a shot, but I need it to match a certain number of points on the spherical shape, and I'd like a system I can build on. I think if this method works it should be able to deform any shape about any other shape, it just needs one crucial thing which is to work with an entire transform matrix instead of just position.

So, if I have P, N, up ... could this be turned into a transform matrix so I can compute the offset of the deform points relative to the other pts?

If you want to maintain the relative position of all the points inside the sphere its somewhat more tricky than that. There's an asset i made in vops on exchange, search for wrap deformer that does what you are trying. The problem with this method is as points get further from the surface neighbouring points can start to be influenced in very different ways...

Edited by sibarrick
Link to comment
Share on other sites

If you want to maintain the relative position of all the points inside the sphere its somewhat more tricky than that. There's an asset i made in vops on exchange, search for wrap deformer that does what you are trying. The problem with this method is as points get further from the surface neighbouring points can start to be influenced in very different ways...

Hmm, how so? I've always been curious about skin methods but never dived this deep before. Right now I've got everything weighted to a percentage so that everything adds up to 100% weights. So, regardless of where the points move, they should always get weighted the same way based on their positions.

Why would being farther away make a difference? As long as the original sphere (or whatever else) doesn't move it should always effect it the same right?

Link to comment
Share on other sites

Well it depends exactly on how exactly you have done it of course...

But say you are using the distance of the point from the surface as a weighted falloff. Then there is always the chance that when you concider 2 neighbouring points inside the sphere 1 will be inside the influence radius of half the points (for simplicity lets just say the left hand set of polys in your sphere) whereas the neighbouring point is influenced by the other half (again for simplicity say the right hand set of polys in your sphere). Now if the right hand set of polys is animating in a very different way to the left you can end up with your 2 neighbouring points crossing over... and therefore loosing their relative positions.

When points are very close to the surface of the sphere this is less likely to happen because the weighting will be strongly "attaching" your point to a particular polygon, hence the problem is more likely to happen as points move towards the center.

Now you may set your radius falloff to be so high that all the points are influenced by all the polys but then you have a lot of averaging going on and the points won't follow very closely what the sphere is really doing.

Now if everything is all very "soft" and not too "dramatic" you may not really notice any of this and it will all be fine... :)

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...