Code
#include <opencv2/core/core.hpp>
#include <opencv2/imgproc/imgproc.hpp>
#include <opencv2/highgui/highgui.hpp>
int main( )
{
cv::Mat image;
image = cvLoadImage( img.jpg );
cv::namedWindow( "Display Image", CV_WINDOW_AUTOSIZE );
cv::imshow( "Display Image", image );
cv::waitKey(0);
return 0;
}
Build log
----------Build Started--------
C:\Windows\system32\cmd.exe /c ""mingw32-make.exe" -j 2 -f "CV_wsp.mk""
----------Building project:[ Histogram - Debug ]----------
mingw32-make.exe[1]: Entering directory `C:/Users/Nadvi/Documents/CodeLite/CV/Histogram'
g++ -o ./Debug/Histogram ./Debug/main.o -L. -LT:/OpenCV2.3/lib -lT:/OpenCV2.3/include/opencv2
t:/codelite/mingw-4.4.1/bin/../lib/gcc/mingw32/4.4.1/../../../../mingw32/bin/ld.exe: cannot find -lT:/OpenCV2.3/include/opencv2
collect2: ld returned 1 exit status
mingw32-make.exe[1]: *** [Debug/Histogram] Error 1
mingw32-make.exe[1]: Leaving directory `C:/Users/Nadvi/Documents/CodeLite/CV/Histogram'
mingw32-make.exe: *** [All] Error 2
----------Build Ended----------
0 errors, 0 warnings
Debug Log
Using gdbinit file: C:\Users\Nadvi\AppData\Local\Temp\codelite_gdbinit.txt
Current working dir: C:\Users\Nadvi\Documents\CodeLite\CV\Histogram
Launching gdb from : C:/Users/Nadvi/Documents/CodeLite/CV/Histogram/Debug
Starting debugger : gdb --command="C:\Users\Nadvi\AppData\Local\Temp\codelite_gdbinit.txt" --interpreter=mi "./Histogram"
DEBUG>>set new-console on
DEBUG>>set unwindonsignal on
DEBUG>>set breakpoint pending on
DEBUG>>catch throw
DEBUG>>set width 0
DEBUG>>set height 0
DEBUG>>set print elements 200
Debug session started successfully!
DEBUG>>00000001-exec-arguments
DEBUG>>00000002-exec-run
DEBUG>>~"GNU gdb (GDB) 7.0.1\n"
GNU gdb (GDB) 7.0.1
DEBUG>>~"Copyright (C) 2009 Free Software Foundation, Inc.\n"
Copyright (C) 2009 Free Software Foundation, Inc.
DEBUG>>~"License GPLv3+: GNU GPL version 3 or later <
http://gnu.org/licenses/gpl.html>\n"
License GPLv3+: GNU GPL version 3 or later <
http://gnu.org/licenses/gpl.html>
DEBUG>>~"This is free software: you are free to change and redistribute it.\n"
This is free software: you are free to change and redistribute it.
DEBUG>>~"There is NO WARRANTY, to the extent permitted by law. Type \"show copying\"\n"
There is NO WARRANTY, to the extent permitted by law. Type "show copying"
DEBUG>>~"and \"show warranty\" for details.\n"
and "show warranty" for details.
DEBUG>>~"This GDB was configured as \"mingw32\".\n"
This GDB was configured as "mingw32".
DEBUG>>~"For bug reporting instructions, please see:\n"
For bug reporting instructions, please see:
DEBUG>>~"<
http://www.gnu.org/software/gdb/bugs/>...\n"
<
http://www.gnu.org/software/gdb/bugs/>...
DEBUG>>&"./Histogram: No such file or directory.\n"
DEBUG>>&"set new-console on\n"
DEBUG>>^done
DEBUG>>&"set unwindonsignal on\n"
DEBUG>>^done
DEBUG>>&"set breakpoint pending on\n"
DEBUG>>^done
DEBUG>>&"catch throw\n"
DEBUG>>&"No symbol table is loaded. Use the \"file\" command.\n"
DEBUG>>~"Catchpoint 1 (throw)\n"
Catchpoint 1 (throw)
DEBUG>>^done
DEBUG>>&"set width 0\n"
DEBUG>>^done
DEBUG>>&"set height 0\n"
DEBUG>>^done
DEBUG>>&"set print elements 200\n"
DEBUG>>^done
DEBUG>>00000001^done
DEBUG>>00000002^error,msg="No executable specified, use `target exec'."
DEBUG>>00000003-var-update "*"
DEBUG>>00000003^done,changelist=[]
Debug session ended
No executable specified, use `target exec'.