Unable to Debug an OpenCV code, Error msg "Cannot find or open the PDB File"

EDN Admin

Well-known member
Joined
Aug 7, 2010
Messages
12,794
Location
In the Machine
<br/>
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black Hi,

<p style="margin-bottom:0.0001pt; line-height:normal
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black I tried a sample OpenCV code given below which displays a picture. I use the following components for it ( Open CV 2.2, CMake
2.8.4, Visual Studio 2010 Professional)
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black I installed and configured all these as mentioned.

<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black I have even build the solution without any error, when i try to debug it a pop up window appears for a fraction of a second
and then displays the below message in the output window
<p style="margin-bottom:0.0001pt; line-height:normal
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:UsersDellDocumentsVisual Studio 2010ProjectsTest1DebugTest1.exe, Symbols loaded. <span style="font-size:7.5pt; font-family:Consolas; color:black
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64ntdll.dll, Cannot find or open the PDB file <span style="font-size:7.5pt; font-family:Consolas; color:black
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64kernel32.dll, Cannot find or open the PDB file <span style="font-size:7.5pt; font-family:Consolas; color:black
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64KernelBase.dll, Cannot find or open the PDB file <span style="font-size:7.5pt; font-family:Consolas; color:black
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:OpenCV2.2binopencv_core220d.dll, Cannot find or open the PDB file <span style="font-size:7.5pt; font-family:Consolas; color:black
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64msvcp100d.dll, Cannot find or open the PDB file <span style="font-size:7.5pt; font-family:Consolas; color:black
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64msvcr100d.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:OpenCV2.2binopencv_highgui220d.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64user32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64gdi32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64lpk.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64usp10.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64msvcrt.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64advapi32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64sechost.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64rpcrt4.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64sspicli.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64cryptbase.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64ole32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:Windowswinsxsx86_microsoft.windows.common-controls_6595b64144ccf1df_5.82.7600.16661_none_ebfb56996c72aefccomctl32.dll,
Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64avifil32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64winmm.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64msacm32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64msvfw32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64shell32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64shlwapi.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64avicap32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64version.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64imm32.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black Test1.exe: Loaded C:WindowsSysWOW64msctf.dll, Cannot find or open the PDB file
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black The program [8008] Test1.exe: Native has exited with code 1 (0x1).
<p style="margin-bottom:0.0001pt; line-height:normal
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:Consolas; color:black I checked the path C:WindowsSysWOW64, and the above mentioned missing DLL files are present in the path.

<p style="margin-bottom:0.0001pt; line-height:normal
<p style="margin-bottom:0.0001pt; line-height:normal <span style="text-decoration:underline <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black Program Code

<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue #include<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "stdafx.h"
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue #include<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "cv.h"
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue #include<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "cxcore.h"
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue #include<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "highgui.h"
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue int<span style="font-size:9.5pt; font-family:Consolas; color:black _tmain(<span style="font-size:9.5pt; font-family:Consolas; color:blue int<span style="font-size:9.5pt; font-family:Consolas; color:black
argc, _TCHAR* argv[])
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black {
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:green // Open the file.
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black IplImage *img = cvLoadImage(<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "photo.jpg"<span style="font-size:9.5pt; font-family:Consolas; color:black );
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue if<span style="font-size:9.5pt; font-family:Consolas; color:black (!img) {
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black printf(<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "Error: Couldnt open the image file.n"<span style="font-size:9.5pt; font-family:Consolas; color:black );
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue return<span style="font-size:9.5pt; font-family:Consolas; color:black 1;
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black }
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:green // Display the image.
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black cvNamedWindow(<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "Image:"<span style="font-size:9.5pt; font-family:Consolas; color:black ,
CV_WINDOW_AUTOSIZE);
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black cvShowImage(<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "Image:"<span style="font-size:9.5pt; font-family:Consolas; color:black ,
img);
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:green // Wait for the user to press a key in the GUI window.
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black cvWaitKey(0);
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:green // Free the resources.
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black cvDestroyWindow(<span style="font-size:9.5pt; font-family:Consolas; color:#a31515 "Image:"<span style="font-size:9.5pt; font-family:Consolas; color:black );
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black cvReleaseImage(&img);
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:blue return<span style="font-size:9.5pt; font-family:Consolas; color:black 0;
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:9.5pt; font-family:Consolas; color:black }<span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black

<p style="margin-bottom:0.0001pt; line-height:normal
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black Kindly give a solution.

<p style="margin-bottom:0.0001pt; line-height:normal
<p style="margin-bottom:0.0001pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black Best regards,
<p style="margin-bottom:6pt; line-height:normal <span style="font-size:7.5pt; font-family:"Verdana","sans-serif"; color:black Gopinath
<br/>

View the full article
 
Back
Top