27 #ifndef G2O_ROBUST_KERNEL_FACTORY_H 28 #define G2O_ROBUST_KERNEL_FACTORY_H 76 static void destroy();
86 void unregisterType(
const std::string& tag);
101 void fillKnownKernels(std::vector<std::string>&
types)
const;
105 typedef std::map<std::string, AbstractRobustKernelCreator*>
CreatorMap;
133 #if defined _MSC_VER && defined G2O_SHARED_LIBS 134 # define G2O_ROBUST_KERNEL_FACTORY_EXPORT __declspec(dllexport) 135 # define G2O_ROBUST_KERNEL_FACTORY_IMPORT __declspec(dllimport) 137 # define G2O_ROBUST_KERNEL_FACTORY_EXPORT 138 # define G2O_ROBUST_KERNEL_FACTORY_IMPORT 142 #define G2O_REGISTER_ROBUST_KERNEL(name, classname) \ 143 extern "C" void G2O_ROBUST_KERNEL_FACTORY_EXPORT g2o_robust_kernel_##classname(void) {} \ 144 static g2o::RegisterRobustKernelProxy<classname> g_robust_kernel_proxy_##classname(#name); 146 #define G2O_USE_ROBUST_KERNEL(classname) \ 147 extern "C" void G2O_ROBUST_KERNEL_FACTORY_IMPORT g2o_robust_kernel_##classname(void); \ 148 static g2o::TypeFunctionProxy proxy_##classname(g2o_robust_kernel_##classname); void unregisterType(const std::string &tag)
stuff to open files and other unsorted components ProjectiveCamera types
RegisterRobustKernelProxy(const std::string &name)
some general case utility functions
Abstract interface for allocating a robust kernel.
CreatorMap _creator
look-up map for the existing creators
std::map< std::string, AbstractRobustKernelCreator * > CreatorMap
create robust kernels based on their human readable name
static RobustKernelFactory * instance()
return the instance
~RegisterRobustKernelProxy()
static RobustKernelFactory * factoryInstance
virtual ~AbstractRobustKernelCreator()
base for all robust cost functions
templatized creator class which creates graph elements
void registerRobustKernel(const std::string &tag, AbstractRobustKernelCreator *c)
RobustKernel * construct()