Constraint limits setup functionals confusion

Post Reply
User avatar
SynapticBytes
Posts: 74
Joined: Thu Feb 10, 2011 8:27 pm

Constraint limits setup functionals confusion

Post by SynapticBytes »

So for my plugin development, I've gone through all the different constraint types, and tries to match up functionality to see what functions I should re-implement. Constraint limits seems to be confusing.

- setLimit exists for Hinge, Conetwist and Generic6DOF
- setUpperLimit/setLowerLimit exists for Universal and Hinge2
- setLinearLowerLimit/setLinearUpperLimit/setAngularLowerLimit/setAngularUpperLimit exists for generic6DoF
- setLowerLinLimit/setUpperLinLimit/setLowerAngLimit/setUpperAngLimit exists for Slider (along with softness/restitution/damping separate functions for Sliders uniquely amongst constraints

Now, and these all basically the same functionality, with just inconsistent naming between constraints? OR do they all work completely differently so justify all being different functions?

Ideally, I would prefer to re-implement one limit setting functions only similar to the setLimit function, although even setLimit has different parameter for different constraints. Does that sound feasible?

Am I missing something on the different functions? Are some setting the limit axes while others are setting the limit values? FOr example, with generic6dof, setLinearLowerLimit is a vector, while setLimit is an axis and 2 scalars. I'm confused. Can someone explain the differences?

Thanks.
Post Reply