I am using Version 2.4.13.6 of OpenCV.
Finally, change the DLL library project properties, C/C++, code generation, runtime: Multithreaded debugging (/MTd) to multithreaded DLL debugging (/MDd).
That is:
In UI project, Configuration Properties -> General ->MFC Use, select Use MFC in shared DLL;
In the Algorithm DLL library project, Debug, Configuration Properties ->C/C++-> Code Generation -> Runtime, select Multithreaded DLL Debugging (/MDd).
Probable cause:
__acrt_first_block == header = new[] = new[] = new[] = new[]; I didn’t use new in my application. I learned that vector allocates memory dynamically, so this is where the problem most likely occurred.
——————————————————–end——————————————————
There are also a lot of articles on the Internet that say manual allocation of memory, I have tried, in my this has no effect.
vector
hierarchy(10000); vector
contours(10000); FindContours (Dst, contours, hierarchy, CV_RETR_CCOMP, CV_CHAIN_APPROX_NONE); // Note that the memory space is too large, otherwise the program will crash.**
—
reference
Blog.csdn.net/auto1993/ar…
Bbs.csdn.net/topics/3910…