Skip to content

Commit

Permalink
Suffix 'Offset' added to the members '*TibialTorsion' and '*AnkleAbAd…
Browse files Browse the repository at this point in the history
…d' and associated methods.
  • Loading branch information
Alzathar committed Nov 2, 2016
1 parent 798c83a commit 343f9dc
Show file tree
Hide file tree
Showing 4 changed files with 60 additions and 60 deletions.
12 changes: 6 additions & 6 deletions modules/body/include/openma/body/plugingait.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ namespace body
void setRightAsisTrochanterAPDistance(double value) _OPENMA_NOEXCEPT;
double leftAsisTrochanterAPDistance() const _OPENMA_NOEXCEPT;
void setLeftAsisTrochanterAPDistance(double value) _OPENMA_NOEXCEPT;
double rightTibialTorsion() const _OPENMA_NOEXCEPT;
void setRightTibialTorsion(double value) _OPENMA_NOEXCEPT;
double leftTibialTorsion() const _OPENMA_NOEXCEPT;
void setLeftTibialTorsion(double value) _OPENMA_NOEXCEPT;
double rightTibialTorsionOffset() const _OPENMA_NOEXCEPT;
void setRightTibialTorsionOffset(double value) _OPENMA_NOEXCEPT;
double leftTibialTorsionOffset() const _OPENMA_NOEXCEPT;
void setLeftTibialTorsionOffset(double value) _OPENMA_NOEXCEPT;
double rightThighRotationOffset() const _OPENMA_NOEXCEPT;
void setRightThighRotationOffset(double value) _OPENMA_NOEXCEPT;
double leftThighRotationOffset() const _OPENMA_NOEXCEPT;
Expand All @@ -114,8 +114,8 @@ namespace body
double rightStaticRotationOffset() const _OPENMA_NOEXCEPT;
double leftStaticPlantarFlexionOffset() const _OPENMA_NOEXCEPT;
double leftStaticRotationOffset() const _OPENMA_NOEXCEPT;
double rightAnkleAbAdd() const _OPENMA_NOEXCEPT;
double leftAnkleAbAdd() const _OPENMA_NOEXCEPT;
double rightAnkleAbAddOffset() const _OPENMA_NOEXCEPT;
double leftAnkleAbAddOffset() const _OPENMA_NOEXCEPT;

virtual bool calibrate(Node* trials, Subject* subject) override;
virtual LandmarksTranslator* defaultLandmarksTranslator() override;
Expand Down
16 changes: 8 additions & 8 deletions modules/body/include/openma/body/plugingait_p.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,8 @@ namespace body
Property<PluginGait, double, &PluginGait::leftLegLength, &PluginGait::setLeftLegLength> {"leftLegLength"},
Property<PluginGait, double, &PluginGait::rightAsisTrochanterAPDistance, &PluginGait::setRightAsisTrochanterAPDistance> {"rightAsisTrochanterAPDistance"},
Property<PluginGait, double, &PluginGait::leftAsisTrochanterAPDistance, &PluginGait::setLeftAsisTrochanterAPDistance> {"leftAsisTrochanterAPDistance"},
Property<PluginGait, double, &PluginGait::rightTibialTorsion, &PluginGait::setRightTibialTorsion> {"rightTibialTorsion"},
Property<PluginGait, double, &PluginGait::leftTibialTorsion, &PluginGait::setLeftTibialTorsion> {"leftTibialTorsion"},
Property<PluginGait, double, &PluginGait::rightTibialTorsionOffset, &PluginGait::setRightTibialTorsionOffset> {"rightTibialTorsionOffset"},
Property<PluginGait, double, &PluginGait::leftTibialTorsionOffset, &PluginGait::setLeftTibialTorsionOffset> {"leftTibialTorsionOffset"},
Property<PluginGait, double, &PluginGait::rightThighRotationOffset, &PluginGait::setRightThighRotationOffset> {"rightThighRotationOffset"},
Property<PluginGait, double, &PluginGait::leftThighRotationOffset, &PluginGait::setLeftThighRotationOffset> {"leftThighRotationOffset"},
Property<PluginGait, double, &PluginGait::rightShankRotationOffset, &PluginGait::setRightShankRotationOffset> {"rightShankRotationOffset"},
Expand All @@ -105,8 +105,8 @@ namespace body
Property<PluginGait, double, &PluginGait::rightStaticRotationOffset> {"rightStaticRotationOffset"},
Property<PluginGait, double, &PluginGait::leftStaticPlantarFlexionOffset> {"leftStaticPlantarFlexionOffset"},
Property<PluginGait, double, &PluginGait::leftStaticRotationOffset> {"leftStaticRotationOffset"},
Property<PluginGait, double, &PluginGait::rightAnkleAbAdd> {"rightAnkleAbAdd"},
Property<PluginGait, double, &PluginGait::leftAnkleAbAdd> {"leftAnkleAbAdd"}
Property<PluginGait, double, &PluginGait::rightAnkleAbAddOffset> {"rightAnkleAbAddOffset"},
Property<PluginGait, double, &PluginGait::leftAnkleAbAddOffset> {"leftAnkleAbAddOffset"}
)

public:
Expand Down Expand Up @@ -138,8 +138,8 @@ namespace body
double LeftLegLength;
double RightAsisTrochanterAPDistance;
double LeftAsisTrochanterAPDistance;
double RightTibialTorsion;
double LeftTibialTorsion;
double RightTibialTorsionOffset;
double LeftTibialTorsionOffset;
double RightThighRotationOffset;
double LeftThighRotationOffset;
double RightShankRotationOffset;
Expand All @@ -156,8 +156,8 @@ namespace body
double RightStaticRotationOffset;
double LeftStaticPlantarFlexionOffset;
double LeftStaticRotationOffset;
double RightAnkleAbAdd;
double LeftAnkleAbAdd;
double RightAnkleAbAddOffset;
double LeftAnkleAbAddOffset;

using CalibrateJointFuncPtr = bool (*)(math::Position* , std::vector<double*>& , PluginGaitPrivate* , ummp* , const std::string& , double , double , const math::Position* );
CalibrateJointFuncPtr CalibrateKneeJointCentre;
Expand Down
80 changes: 40 additions & 40 deletions modules/body/src/plugingait.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,8 @@ namespace body
LeftLegLength(0.0),
RightAsisTrochanterAPDistance(0.0),
LeftAsisTrochanterAPDistance(0.0),
RightTibialTorsion(0.0),
LeftTibialTorsion(0.0),
RightTibialTorsionOffset(0.0),
LeftTibialTorsionOffset(0.0),
RightThighRotationOffset(0.0),
LeftThighRotationOffset(0.0),
RightShankRotationOffset(0.0),
Expand All @@ -182,8 +182,8 @@ namespace body
RightStaticRotationOffset(0.0),
LeftStaticPlantarFlexionOffset(0.0),
LeftStaticRotationOffset(0.0),
RightAnkleAbAdd(0.0),
LeftAnkleAbAdd(0.0),
RightAnkleAbAddOffset(0.0),
LeftAnkleAbAddOffset(0.0),
CalibrateKneeJointCentre(nullptr),
CalibrateAnkleJointCentre(nullptr)
{};
Expand All @@ -208,10 +208,10 @@ namespace body
footFlat = this->LeftFootFlatEnabled;
staticPlantarFlexionOffset = &(this->LeftStaticPlantarFlexionOffset);
staticRotationOffset = &(this->LeftStaticRotationOffset);
tibialTorsion = &(this->LeftTibialTorsion);
tibialTorsionOffset = &(this->LeftTibialTorsionOffset);
thighRotationOffset = &(this->LeftThighRotationOffset);
shankRotationOffset = &(this->LeftShankRotationOffset);
ankleAbAdd = &(this->LeftAnkleAbAdd);
ankleAbAddOffset = &(this->LeftAnkleAbAddOffset);
}
else if (side == Side::Right)
{
Expand All @@ -222,17 +222,17 @@ namespace body
footFlat = this->RightFootFlatEnabled;
staticPlantarFlexionOffset = &(this->RightStaticPlantarFlexionOffset);
staticRotationOffset = &(this->RightStaticRotationOffset);
tibialTorsion = &(this->RightTibialTorsion);
tibialTorsionOffset = &(this->RightTibialTorsionOffset);
thighRotationOffset = &(this->RightThighRotationOffset);
shankRotationOffset = &(this->RightShankRotationOffset);
ankleAbAdd = &(this->RightAnkleAbAdd);
ankleAbAddOffset = &(this->RightAnkleAbAddOffset);
}
else
{
error("PluginGait - Unknown side for the lower limb. Calibration aborted.");
return false;
}
std::vector<double*> offsets{thighRotationOffset, shankRotationOffset, tibialTorsion, ankleAbAdd};
std::vector<double*> offsets{thighRotationOffset, shankRotationOffset, tibialTorsionOffset, ankleAbAddOffset};
// -----------------------------------------
// Thigh
// -----------------------------------------
Expand Down Expand Up @@ -883,14 +883,14 @@ namespace body
double LeftAsisTrochanterAPDistance;
/**
* [Optional] This property holds the angle between projection of knee Flexion Axis (Y) with projection of the ankle Flexion Axis (Y) onto the plane perpendicular to the longitudinal shank axis. By default, this property contains the value 0.0.
* @sa rightTibialTorsion() setRightTibialTorsion()
* @sa rightTibialTorsionOffset() setRightTibialTorsionOffset()
*/
double RightTibialTorsion;
double RightTibialTorsionOffset;
/**
* [Optional] This property holds the angle between projection of knee Flexion Axis (Y) with projection of the ankle Flexion Axis (Y) onto the plane perpendicular to the longitudinal shank axis. By default, this property contains the value 0.0.
* @sa leftTibialTorsion() setLeftTibialTorsion()
* @sa leftTibialTorsionOffset() setLeftTibialTorsionOffset()
*/
double LeftTibialTorsion;
double LeftTibialTorsionOffset;
/**
* [Optional] This property holds the angle between projection of Thigh wand marker with the projection of the knee Flexion Axis (Y) onto the plane perpendicular to the longitudinal thigh axis. By default, this property contains the value 0.0.
* @sa rightThighRotationOffset() setRightThighRotationOffset()
Expand Down Expand Up @@ -968,14 +968,14 @@ namespace body
double LeftStaticRotationOffset;
/**
* [Calculated] This property holds the projection of the ankle flexion axis with projection of the vector delimited by AJC and ANK onto the plane defined by the shank axis. By default, this property contains the value 0.0.
* @sa rightAnkleAbAdd()
* @sa rightAnkleAbAddOffset()
*/
double RightAnkleAbAdd;
double RightAnkleAbAddOffset;
/**
* [Calculated] This property holds the projection of the ankle flexion axis with projection of the vector delimited by AJC and ANK onto the plane defined by the shank axis. By default, this property contains the value 0.0.
* @sa leftAnkleAbAdd()
* @sa leftAnkleAbAddOffset()
*/
double LeftAnkleAbAdd;
double LeftAnkleAbAddOffset;
};
#endif

Expand Down Expand Up @@ -1914,44 +1914,44 @@ namespace body
};

/**
* Returns the internal parameter RightTibialTorsion.
* Returns the internal parameter RightTibialTorsionOffset.
*/
double PluginGait::rightTibialTorsion() const _OPENMA_NOEXCEPT
double PluginGait::rightTibialTorsionOffset() const _OPENMA_NOEXCEPT
{
auto optr = this->pimpl();
return optr->RightTibialTorsion;
return optr->RightTibialTorsionOffset;
};

/**
* Sets the internal parameter RightTibialTorsion.
*/
void PluginGait::setRightTibialTorsion(double value) _OPENMA_NOEXCEPT
void PluginGait::setRightTibialTorsionOffset(double value) _OPENMA_NOEXCEPT
{
auto optr = this->pimpl();
if (fabs(value - optr->RightTibialTorsion) < std::numeric_limits<double>::epsilon())
if (fabs(value - optr->RightTibialTorsionOffset) < std::numeric_limits<double>::epsilon())
return;
optr->RightTibialTorsion = value;
optr->RightTibialTorsionOffset = value;
this->modified();
};

/**
* Returns the internal parameter LeftTibialTorsion.
* Returns the internal parameter LeftTibialTorsionOffset.
*/
double PluginGait::leftTibialTorsion() const _OPENMA_NOEXCEPT
double PluginGait::leftTibialTorsionOffset() const _OPENMA_NOEXCEPT
{
auto optr = this->pimpl();
return optr->LeftTibialTorsion;
return optr->LeftTibialTorsionOffset;
};

/**
* Sets the internal parameter LeftTibialTorsion.
* Sets the internal parameter LeftTibialTorsionOffset.
*/
void PluginGait::setLeftTibialTorsion(double value) _OPENMA_NOEXCEPT
void PluginGait::setLeftTibialTorsionOffset(double value) _OPENMA_NOEXCEPT
{
auto optr = this->pimpl();
if (fabs(value - optr->LeftTibialTorsion) < std::numeric_limits<double>::epsilon())
if (fabs(value - optr->LeftTibialTorsionOffset) < std::numeric_limits<double>::epsilon())
return;
optr->LeftTibialTorsion = value;
optr->LeftTibialTorsionOffset = value;
this->modified();
};

Expand Down Expand Up @@ -2202,21 +2202,21 @@ namespace body
};

/**
* Returns the internal parameter RightAnkleAbAdd.
* Returns the internal parameter RightAnkleAbAddOffset.
*/
double PluginGait::rightAnkleAbAdd() const _OPENMA_NOEXCEPT
double PluginGait::rightAnkleAbAddOffset() const _OPENMA_NOEXCEPT
{
auto optr = this->pimpl();
return optr->RightAnkleAbAdd;
return optr->RightAnkleAbAddOffset;
};

/**
* Returns the internal parameter LeftAnkleAbAdd.
* Returns the internal parameter LeftAnkleAbAddOffset.
*/
double PluginGait::leftAnkleAbAdd() const _OPENMA_NOEXCEPT
double PluginGait::leftAnkleAbAddOffset() const _OPENMA_NOEXCEPT
{
auto optr = this->pimpl();
return optr->LeftAnkleAbAdd;
return optr->LeftAnkleAbAddOffset;
};

// ----------------------------------------------------------------------- //
Expand Down Expand Up @@ -2379,8 +2379,8 @@ namespace body
optr->LeftLegLength = optr_src->LeftLegLength;
optr->RightAsisTrochanterAPDistance = optr_src->RightAsisTrochanterAPDistance;
optr->LeftAsisTrochanterAPDistance = optr_src->LeftAsisTrochanterAPDistance;
optr->RightTibialTorsion = optr_src->RightTibialTorsion;
optr->LeftTibialTorsion = optr_src->LeftTibialTorsion;
optr->RightTibialTorsionOffset = optr_src->RightTibialTorsionOffset;
optr->LeftTibialTorsionOffset = optr_src->LeftTibialTorsionOffset;
optr->RightThighRotationOffset = optr_src->RightThighRotationOffset;
optr->LeftThighRotationOffset = optr_src->LeftThighRotationOffset;
optr->RightShankRotationOffset = optr_src->RightShankRotationOffset;
Expand All @@ -2396,8 +2396,8 @@ namespace body
optr->RightStaticRotationOffset = optr_src->RightStaticRotationOffset;
optr->LeftStaticPlantarFlexionOffset = optr_src->LeftStaticPlantarFlexionOffset;
optr->LeftStaticRotationOffset = optr_src->LeftStaticRotationOffset;
optr->RightAnkleAbAdd = optr_src->RightAnkleAbAdd;
optr->LeftAnkleAbAdd = optr_src->LeftAnkleAbAdd;
optr->RightAnkleAbAddOffset = optr_src->RightAnkleAbAddOffset;
optr->LeftAnkleAbAddOffset = optr_src->LeftAnkleAbAddOffset;
};
};
};
12 changes: 6 additions & 6 deletions modules/body/swig/body/plugingait.i
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ namespace body
void setRightAsisTrochanterAPDistance(double value);
double leftAsisTrochanterAPDistance() const;
void setLeftAsisTrochanterAPDistance(double value);
double rightTibialTorsion() const;
void setRightTibialTorsion(double value);
double leftTibialTorsion() const;
void setLeftTibialTorsion(double value);
double rightTibialTorsionOffset() const;
void setRightTibialTorsionOffset(double value);
double leftTibialTorsionOffset() const;
void setLeftTibialTorsionOffset(double value);
double rightThighRotationOffset() const;
void setRightThighRotationOffset(double value);
double leftThighRotationOffset() const;
Expand All @@ -113,8 +113,8 @@ namespace body
double rightStaticRotationOffset() const;
double leftStaticPlantarFlexionOffset() const;
double leftStaticRotationOffset() const;
double rightAnkleAbAdd() const;
double leftAnkleAbAdd() const;
double rightAnkleAbAddOffset() const;
double leftAnkleAbAddOffset() const;
};
%clearnodefaultctor;
};
Expand Down

0 comments on commit 343f9dc

Please sign in to comment.