| OpenCV 3.4.8 Open Source Computer Vision

Classes | Namespaces | Macros | Functions
layer.details.hpp File Reference
`#include <opencv2/dnn/layer.hpp>`

## Classes
class | cv::dnn::details::_LayerStaticRegisterer

## Namespaces
| cv
| cv::dnn
| cv::dnn::details

## Macros
#define | CV_DNN_REGISTER_LAYER_CLASS(type, class) cv::dnn::LayerFactory::registerLayer(#type, cv::dnn::details::_layerDynamicRegisterer<class>);
| Registers layer class in runtime. More...
#define | CV_DNN_REGISTER_LAYER_CLASS_STATIC(type, class)
| Registers layer class on module load time. More...
#define | CV_DNN_REGISTER_LAYER_FUNC(type, constructorFunc) cv::dnn::LayerFactory::registerLayer(#type, constructorFunc);
| Registers layer constructor in runtime. More...
#define | CV_DNN_REGISTER_LAYER_FUNC_STATIC(type, constructorFunc) static cv::dnn::details::_LayerStaticRegisterer __LayerStaticRegisterer_##type(#type, constructorFunc);
| Registers layer constructor on module load time. More...

## Functions
template<typename LayerClass >
Ptr< Layer > | cv::dnn::details::_layerDynamicRegisterer (LayerParams &params)

## Macro Definition Documentation

## § CV_DNN_REGISTER_LAYER_CLASS

#define CV_DNN_REGISTER_LAYER_CLASS | ( |  | type,
|  |  | class
| ) |  | cv::dnn::LayerFactory::registerLayer(#type, cv::dnn::details::_layerDynamicRegisterer<class>);

Registers layer class in runtime.

Parameters

  type | string, containing type name of the layer.
  class | C++ class, derived from Layer.

This macros must be placed inside the function code.

## § CV_DNN_REGISTER_LAYER_CLASS_STATIC

#define CV_DNN_REGISTER_LAYER_CLASS_STATIC | ( |  | type,
|  |  | class
| ) |  |

Value:
Ptr<Layer> __LayerStaticRegisterer_func_##type(LayerParams &params) \
{ return Ptr<Layer>(new class(params)); } \
static cv::dnn::details::_LayerStaticRegisterer __LayerStaticRegisterer_##type(#type, __LayerStaticRegisterer_func_##type);
cv::dnn::details::_LayerStaticRegisterer
Definition: layer.details.hpp:57

Registers layer class on module load time.

Parameters

  type | string, containing type name of the layer.
  class | C++ class, derived from Layer.

This macros must be placed outside the function code.

## § CV_DNN_REGISTER_LAYER_FUNC

#define CV_DNN_REGISTER_LAYER_FUNC | ( |  | type,
|  |  | constructorFunc
| ) |  | cv::dnn::LayerFactory::registerLayer(#type, constructorFunc);

Registers layer constructor in runtime.

Parameters

  type | string, containing type name of the layer.
  constructorFunc | pointer to the function of type LayerRegister::Constructor, which creates the layer.

This macros must be placed inside the function code.

## § CV_DNN_REGISTER_LAYER_FUNC_STATIC

#define CV_DNN_REGISTER_LAYER_FUNC_STATIC | ( |  | type,
|  |  | constructorFunc
| ) |  | static cv::dnn::details::_LayerStaticRegisterer __LayerStaticRegisterer_##type(#type, constructorFunc);

Registers layer constructor on module load time.

Parameters

  type | string, containing type name of the layer.
  constructorFunc | pointer to the function of type LayerRegister::Constructor, which creates the layer.

This macros must be placed outside the function code.