The first is getting shifted muscles to deform as though they are getting pushed instead of just maintaining their shape. To deal with this, I thought it would be a good idea to get the magnitude of its intended displacement vector and then normalize this vector, multiplying it by the magnitude minus the distance between the 2 circles. This is great when the direction of the displacement vector is in the same direction as the 2 points you're measuring to get distance, not so great when its different. I'm not really sure how to measure the distance between 2 ellipses given a vector (although there's probably a way to do it).
The second problem I'm running into is that the shifting muscles always move along with the guide muscle if it determines the muscles are close enough to be shifted (i.e. they have intersecting bounding boxes). This is often fine, but there are cases (such as if a muscle goes backwards or up) that don't work right (see diagram below). What I need to do is make them shift only if 1 muscle passes through the other as its moving, which is getting me back to physically based simulation territory.
I'm feeling like I should maybe take another look at a hair dynamics solution again. While there were certainly several disadvantages to this method that I saw when I first looked into them, they seem like they might be more surmountable. Then again, other problems seem less surmountable, so maybe that's just frustration talking.
No comments:
Post a Comment