You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are four different objects whose parameters are parsed explicitly by the calibration job definition. Because of this, should a developer decide to add a new object of any of these types, they must also add the parsing of any particular parameters to the calibraiton_job_definition's parser.
It makes more sense to have the parsing of object parameters be performed by each object.
The three objects which should have this change are:
Camera defined in camera.h
Target defined in target.h
TransformInterface defined in transform_interface.hpp
Trigger defined in trigger.h
Ideally, these classes will have minimal constructors and a virtual member function called either init() or parse_parameters() which will initialize all necessary member values using the yaml node.
In this way calibration_job_definition.cpp could simply instantiate the correct object type, and then call its parser/init function. This still does not eliminate the need to add code to calibration_job_definition to instantiate a new object when one is created. I see no way around this except to create plugins for each of these object types. However it does clean up the higher level parser and pushes the responsibility of parsing particular parameters to the object that needs them.
The text was updated successfully, but these errors were encountered:
There are four different objects whose parameters are parsed explicitly by the calibration job definition. Because of this, should a developer decide to add a new object of any of these types, they must also add the parsing of any particular parameters to the calibraiton_job_definition's parser.
It makes more sense to have the parsing of object parameters be performed by each object.
The three objects which should have this change are:
Ideally, these classes will have minimal constructors and a virtual member function called either init() or parse_parameters() which will initialize all necessary member values using the yaml node.
In this way calibration_job_definition.cpp could simply instantiate the correct object type, and then call its parser/init function. This still does not eliminate the need to add code to calibration_job_definition to instantiate a new object when one is created. I see no way around this except to create plugins for each of these object types. However it does clean up the higher level parser and pushes the responsibility of parsing particular parameters to the object that needs them.
The text was updated successfully, but these errors were encountered: