2014-02-24 16:04:19 -0600 | asked a question | C++ Compilation introduce errors I have a multi-threaded C++ windows project in Visual Studio 2010 which uses Qt (5.1.1) and OpenCV (2.4.8). When I build it in Debug mode everything runs fine, but when I build it in Release mode the program crashes. Both configurations are almost identical (just in Release I have Multi-threaded DLL /MD and in Debug Multi-threaded Debug DLL /MDd), I disabled optimizations for the Release, and even enabled debug to catch the error. What's most weird is that the same piece of code that crashes, runs just fine in another console project. The error is internal to OpenCV's code, it's not related to my code, my code is just: As I said in Debug the code runs without a problem, Which calls againg I tried to make a new Visual Studio 2010 project to see if this is a project creation problem but the problem persisted. My guess is that the function adresses are wrong in release mode so when it tries to call This is way beyond my knowledge and I have no idea how to fix this, I appreciate all the help I can get on this problem, because I already exausted all my ideas to fix it.... EDIT : I made a small project so anyone can see what's happening. The files are in: https://app.box.com/s/3owljl44emv57erinrf8 In order to run it, you have to have OpenCV 2.4.8 and Qt 5.1.1 and configure the Visual Studio 2010 project to get the include files from the right places. In the resources folder ... (more) |
2014-02-18 21:25:38 -0600 | commented answer | ellipse() bug found! Thanks, now there is just a weird behaviour I get in findContours() when I compile it as release...it does a stackoverlow....I cant debug it since it's release, but removing findContours() makes the program run nicely...maybe its a bug in the dll? I wish I could foward this to someone more expert than me to analise it further....but I dont know anyone :/ |
2014-02-18 08:15:01 -0600 | received badge | ● Teacher (source) |
2014-02-18 02:01:15 -0600 | received badge | ● Self-Learner (source) |
2014-02-18 01:42:15 -0600 | commented answer | ellipse() bug found! Well I cant accept my own answer, so if someone places one like this I will accept |
2014-02-18 01:41:20 -0600 | answered a question | ellipse() bug found! It was already fixed in the new version, sorry for this. |
2014-02-18 01:32:26 -0600 | commented question | ellipse() bug found! I know, I just cant do it right now...can you check this for me? |
2014-02-13 02:04:55 -0600 | received badge | ● Editor (source) |
2014-02-13 02:03:35 -0600 | asked a question | ellipse() bug found! I am using OpenCV 2.4.6, I cant test it in the most recent versions, so I thougt it will be just better to place it in here...I am sorry if this was already corrected in the most recent ones. If I call being
which makes since for this case Is never != so the The code should be changed to So this way, the vector will be never acessed in case it's empty, crashing the program. I am sorry to not submit this to the repository myself, I just can't upload that code right now. |
2014-02-11 13:25:26 -0600 | asked a question | OpenCV Crashes with Stack Overflow Or Resorce Allocation Error I have a multithread C++ Qt program using OpenCV 2.4.6 under VS2010 where one of the threads run an image processing algorithm. I know my algorithm works because it runs fine in a console applicaiton, and I just copy and paste it in the project....then I get all this weird errors. The code is: When the execution hits So I go to Configuration Properties > Linker > System > Stack Reserve Size and change it to "100000000" (100MB) This time the error changes... I am compiling it as /MDd (Multi-Threaded Debug DLL) and I have also tried to run CMake on OpenCV to clear the option "BUILD_WITH_STATIC_CRT", and I compiled openCV again, and the projects that I saw under the OpenCV solution, all had the /MDd as well as my program does. Does anyone has a guess about what is going on? EDIT: Just to make it clear, I have enough free memory in my system to run the program. |