Fix #27279: IK bone rotation limits set to 0 disabled the limit, this was

unintentional, since there is already a toggle to enable/disable it.
This commit is contained in:
Brecht Van Lommel
2011-05-12 08:34:31 +00:00
parent 2f08309ffe
commit 754c134e09

View File

@@ -370,7 +370,7 @@ MT_Vector3 IK_QSphericalSegment::Axis(int dof) const
void IK_QSphericalSegment::SetLimit(int axis, MT_Scalar lmin, MT_Scalar lmax)
{
if (lmin >= lmax)
if (lmin > lmax)
return;
if (axis == 1) {
@@ -613,7 +613,7 @@ void IK_QRevoluteSegment::UpdateAngleApply()
void IK_QRevoluteSegment::SetLimit(int axis, MT_Scalar lmin, MT_Scalar lmax)
{
if (lmin >= lmax || m_axis != axis)
if (lmin > lmax || m_axis != axis)
return;
// clamp and convert to axis angle parameters
@@ -752,7 +752,7 @@ void IK_QSwingSegment::UpdateAngleApply()
void IK_QSwingSegment::SetLimit(int axis, MT_Scalar lmin, MT_Scalar lmax)
{
if (lmin >= lmax)
if (lmin > lmax)
return;
// clamp and convert to axis angle parameters
@@ -898,7 +898,7 @@ void IK_QElbowSegment::UpdateAngleApply()
void IK_QElbowSegment::SetLimit(int axis, MT_Scalar lmin, MT_Scalar lmax)
{
if (lmin >= lmax)
if (lmin > lmax)
return;
// clamp and convert to axis angle parameters