Hello guys,
I have a very urgent question that I really appreciate if you guys help me. I have installed cvblobslib_OpenCV_v8_3 but am not able to use it since it crashes after calling the following function:
blobs = CBlobResult( img, NULL, 100, true );
It shows me this message:
Unhandled exception at 0x75d6c41f in testBlobs.exe: 0xC0000005: C++ Microsoft Exception : int à l ...
OpenCV Error: Incorrect size of input array <Specified element size doesn't match to the size of the specified element type <try to use 0 for element type >> in unknown finction, file ..\..\..\modules\core\src\datastructs.cpp, line 388
and debug output
2010\Projects\testBlobs\Debug\testBlobs.exe', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\ntdll.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\kernel32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\KernelBase.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\opencv231\bin\Debug\opencv_core231d.dll', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msvcp100d.dll', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msvcr100d.dll', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\opencv231\bin\Debug\opencv_highgui231d.dll', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\user32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\gdi32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\lpk.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\usp10.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msvcrt.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\advapi32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\sechost.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\rpcrt4.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\sspicli.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\cryptbase.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\ole32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\oleaut32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\winsxs\x86_microsoft.windows.common-controls_6595b64144ccf1df_5.82.7601.17514_none_ec83dffa859149af\comctl32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\avifil32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\winmm.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msacm32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msvfw32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\shell32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\shlwapi.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\avicap32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\version.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\opencv231\bin\Debug\opencv_imgproc231d.dll', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\mfc100d.dll', Les symboles ont été chargés.
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msimg32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\imm32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msctf.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\uxtheme.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Program Files (x86)\RelevantKnowledge\rlls.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\ws2_32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\nsi.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\oleacc.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\wininet.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\api-ms-win-downlevel-user32-l1-1-0.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\api-ms-win-downlevel-advapi32-l1-1-0.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\api-ms-win-downlevel-shlwapi-l1-1-0.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\api-ms-win-downlevel-version-l1-1-0.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\api-ms-win-downlevel-normaliz-l1-1-0.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\normaliz.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\iertutil.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\psapi.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\ntmarta.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\Wldap32.dll', Cannot find or open the PDB file
Exception de première chance à 0x75d6c41f dans testBlobs.exe : Exception Microsoft C++ : Win32Util::Error à l'emplacement mémoire 0x001fe834..
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\schannel.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\crypt32.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\msasn1.dll', Cannot find or open the PDB file
Exception de première chance à 0x75d6c41f dans testBlobs.exe : Exception Microsoft C++ : Win32Util::Error à l'emplacement mémoire 0x001fe5d0..
Exception de première chance à 0x75d6c41f dans testBlobs.exe : Exception Microsoft C++ : Win32Util::Error à l'emplacement mémoire 0x001fe5d0..
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\dwmapi.dll', Cannot find or open the PDB file
'testBlobs.exe' : Chargé 'C:\Windows\SysWOW64\mfc100fra.dll', Le fichier binaire n'a pas été généré avec les informations de débogage.
Exception de première chance à 0x75d6c41f dans testBlobs.exe : Exception Microsoft C++ : cv::Exception à l'emplacement mémoire 0x001eef78..
Exception de première chance à 0x75d6c41f dans testBlobs.exe : Exception Microsoft C++ : int à l'emplacement mémoire 0x001ff964..
Exception non gérée à 0x75d6c41f dans testBlobs.exe : Exception Microsoft C++ : int à l'emplacement mémoire 0x001ff964..
The complete code is here blog :
#include "cv.h"
include "highgui.h"
include <stdio.h>
include "stdafx.h"
include <conio.h>
// Main blob library include
include "BlobResult.h"
int main()
{
IplImage* img;
IplImage* img2=0;
IplImage* img3=0;
img = cvLoadImage("spots.jpg");
CBlobResult blobs;
CBlob *currentBlob;
img2 = cvCreateImage(cvGetSize(img),img->depth,1);
img3 = cvCreateImage(cvGetSize(img2),img2->depth,1);
cvCvtColor(img,img2,CV_RGB2GRAY);
cvThreshold(img2,img3,100,255,CV_THRESH_BINARY);
uchar backgroundColor = 255;
blobs = CBlobResult(img3, 0,backgroundColor);
// wait for a key
cvWaitKey(0);
// release the image
cvReleaseImage(&img);
return 0;
}
I used this blog's code together with opencv 2.3.1 , visual studio 2010 and windows 7.
Thanks in advance.