SaccadeController configurator for head. More...
#include <Neuro/SaccadeControllerConfigurator.H>
Public Member Functions | |
SaccadeControllerHeadConfigurator (OptionManager &mgr, const std::string &descrName="Saccade Controller Head Configurator", const std::string &tagName="SaccadeControllerHeadConfigurator") | |
Constructor. | |
virtual | ~SaccadeControllerHeadConfigurator () |
destructor | |
nub::ref< SaccadeController > | getSC () const |
Get the chosen SaccadeController. | |
virtual void | paramChanged (ModelParamBase *const param, const bool valueChanged, ParamClient::ChangeStatus *status) |
Intercept people changing our itsSacCtrlName ModelParam. | |
Protected Attributes | |
OModelParam< std::string > | itsSacCtrlType |
Type of the controller. |
SaccadeController configurator for head.
This will export the --hsc-type=XX command-line option and will instantiate a SaccadeController of the desired type as the option gets assigned a value. As this happens, new options may become available in the command-line. To see them, use --help AFTER you have chosen the name of the controller to use. The current head SaccadeController may be retrieved using getSC().
Definition at line 95 of file SaccadeControllerConfigurator.H.
SaccadeControllerHeadConfigurator::SaccadeControllerHeadConfigurator | ( | OptionManager & | mgr, | |
const std::string & | descrName = "Saccade Controller Head Configurator" , |
|||
const std::string & | tagName = "SaccadeControllerHeadConfigurator" | |||
) |
Constructor.
Definition at line 124 of file SaccadeControllerConfigurator.C.
References ModelComponent::addSubComponent().
SaccadeControllerHeadConfigurator::~SaccadeControllerHeadConfigurator | ( | ) | [virtual] |
destructor
Definition at line 135 of file SaccadeControllerConfigurator.C.
nub::ref< SaccadeController > SaccadeControllerHeadConfigurator::getSC | ( | ) | const |
Get the chosen SaccadeController.
You should call this during start() of the ModelComponent that needs the SaccadeController. CAUTION: this may be a rutz::shared_ptr(NULL) if no controller has been chosen.
Definition at line 139 of file SaccadeControllerConfigurator.C.
void SaccadeControllerHeadConfigurator::paramChanged | ( | ModelParamBase *const | param, | |
const bool | valueChanged, | |||
ParamClient::ChangeStatus * | status | |||
) | [virtual] |
Intercept people changing our itsSacCtrlName ModelParam.
See ModelComponent.H; as parsing the command-line or reading a config file sets our name, we'll also here instantiate a controller of the proper type (and export its options)
Reimplemented from ModelComponent.
Definition at line 144 of file SaccadeControllerConfigurator.C.
References ModelComponent::addSubComponent(), ModelComponent::getManager(), OModelParam< T >::getVal(), itsSacCtrlType, MC_RECURSE, ModelComponent::removeSubComponent(), and nub::ref< T >::reset().
Type of the controller.
Definition at line 123 of file SaccadeControllerConfigurator.H.
Referenced by paramChanged().