Monday, June 16, 2008

Solution at last

Hi ppl, I m sorry if I was a little late in posting the follow up for the last blog post. But I was kinda busy with some other stuff. Anyways here is the solution. Well last time i said that the culprit is lib Jasper that is bundled with highgui. The problem is that it is a release version and by default will insist on connecting to release version of the vc runtime. Thus we have to make sure somehow that the application will only connect to the debug version . To do that the option to be set is in Projecct settings -> C/C++ -> Code Generation. In this page there is an option to select runtime library to be used. We have to select either Multithreaded debug or Multithreaded. Any option with DLL in it will cause the program to be dynamically linked with the libraries and also link in MSVCR80.DLL again. But doing this for each and every project is too cumbersome thus you can avoid it by loading the OpenCV workspace direcly and the changing this setting for the highgui library and then rebuilding highgui. The resulting dll will not link to MSVCR80.dll as can be verified with dependency walker (www.dependencywalker.com)

No comments: