AlgorithmInfo initialisation order is undefined (Bug #1876)


Added by Andrey Kamaev almost 13 years ago. Updated almost 13 years ago.


Status:Done Start date:2012-05-02
Priority:High Due date:
Assignee:Vadim Pisarevsky % Done:

0%

Category:core
Target version:2.4.1
Affected version: Operating System:
Difficulty: HW Platform:
Pull request:

Description

Problem: init_module() function(s) can be called before the constructors of AlgorithmInfo's used inside init_module().
See my commit r7856 where I've already fixed this problem for some classes.

Right now there are several new algorithms which uses unsafe initialization pattern. At least the following from features2d module:
  • gftt_info
  • harris_info
  • dense_info

I think OpenCV should use a macro to hide typical part of algorithm setup and avoid this initialisation problem for future Algorithms.


Related issues

blocks Patch #1874: GridAdaptedFeatureDetector Parameters Done 2012-05-02

Associated revisions

Revision fd68cc76
Added by Vadim Pisarevsky almost 13 years ago

fixed 2 build problems on MacOSX (highgui with ffmpeg, opencv_world); added macro CV_INIT_ALGORITHM for simpler algorithm registration (ticket #1876)

History

Updated by Vadim Pisarevsky almost 13 years ago

fixed in r8407

  • Status changed from Open to Done

Also available in: Atom PDF