Class IKDeriv
See Also: Class Control.
class IKDeriv
Description:
This class provides method that a plug-in calls in its implementation of the Control method CompDerivs(). All methods of this class are implemented by the system.
Methods:
Prototype:
virtual int NumEndEffectors()=0;
Remarks:
This method returns the number of end effectors. There may be multiple end effectors if there is branching in the IK chain. For example if the plug-in is a controller controlling a torso there might be two end effectors - the two feet. The plug-ins implementation of CompDerivs() should loop through each end effector and call DP() and DR() for each end effector. Thus this method tells the plug-in how many times it needs to loop.
Return Value:
The number of end effectors
Prototype:
virtual Point3 EndEffectorPos(int index)=0;
Remarks:
If a plug-in needs to know the position of an end effector to calculate its derivative it may call this method to retrieve it. This method is used to return the position of the end effector whose index is passed.
Parameters:
int index
The index of the end effector whose position will be returned.
Prototype:
virtual void DP(Point3 dp,int index)=0;
Remarks:
The plug-in calls this method to specify the derivative of the position of the end effector with respect to the parameter whose index is passed.
Parameters:
Point3 dp
The derivative of the position of the end effector with respect to the parameter.
int index
The index of the end effector.
Prototype:
virtual void DR(Point3 dr,int index)=0;
Remarks:
Implemented by the Plug-In.
Allows the plug-in to specify the derivative of the orientation in terms of Euler angle of the end effector with respect to the parameter.
Parameters:
Point3 dr
The derivative of the orientation in terms of Euler angles of the end effector with respect to the parameter.
int index
The index of the end effector.
Prototype:
virtual void NextDOF()=0;
Remarks:
This method is called after a plug-in has called the above methods DP() and DR() for one of its parameters and it needs to call them again for the next parameter.