'The problem of abnormal exit when using opencv in Qt

When I call the function of opencv to display a picture, the program will exit abnormally. enter image description here

Then I ran the executable directly, and put the required library files into the directory, but the program still couldn't run. enter image description here Has anyone encountered the same problem? The Qt version I use is 5.12, opencv is 4.5.5, and the compiler is MinGW7.3.0, all of which are 64-bit.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source