Dear OpenCV users,
in case you want to explore the OpenCV source code, it helps to create an eclipse project with cmake. Cmake has an eclipse target, which automatically creates a nicely structured eclipse project with sub-projects according to the cmake structure. Here are the instructions:
- Create a workspace folder, e.g. opencvws.
- Select this folder as workspace folder in eclipse using menu "file / switch workspace / other"
- Extract the opencv sources in a subfolder of the workspace folder, e.g. opencv-2.4.9
- In the workspace folder create am eclipse project folder e.g. eclipse-2.4.9. Note: the eclipse project folder must not be a subfolder of the opencv source folder, but a sibling. Both should be directly under the workspace folder.
- Open a terminal and cd to the eclipse project folder
- cmake -G"Eclipse CDT4 - Unix Makefiles" -D CMAKE_BUILD_TYPE=RELEASE -D CMAKE_INSTALL_PREFIX=/usr/local ../opencv-2.4.9
- Import the created eclipse project in eclipse using menu "file / import / general / existing eclipse project" and select the eclispe project folder you created in step 4.
See also http://www.vtk.org/Wiki/Eclipse_CDT4_Generator
I tested this with opencv 2.4.9, eclipse 3.8.1 and cmake 2.8.12.2 on Ubuntu 14.04 LTS.
I tested the project created this way for a day and things like jumping to definitions and the like worked well. I hope it helps!
Best regards,
Michael