I understand that setting anchor hardness (softbody->m_cfg.m_kAHR) to 1 means that the node is expected to stick to the anchor position. But what should setting it to 0 supposed to mean?
I can see two possible answers based on what the code sort of attempts to do:
- Have the node track the velocity of the anchor but let the position drift.
- Disable the anchor entirely.
The second case acts more like a soft anchor.
I suspect a soft anchor is what people mostly want, but that removes the option to track the velocity (without tracking the position), which may be important to some. And a soft anchor can be implemented by using a link with a low linear stiffness attached to a hard anchor. On the other hand that introduces extra complexity and extra parameters in setting up the scene.
Currently the code tracks the velocity when the hardness is set to 0, and it does something nonsensical and wrong involving doubling up the velocity and position tracking when set to 1.
---JvdL---