Please Help! - linking opencv

This is a discussion on Please Help! - linking opencv within the C++ Programming forums, part of the General Programming Boards category; I think I followed all the instructions to the letter on the wiki pages but I can't even get a ...

  1. #1
    Registered User
    Join Date
    Sep 2010
    Posts
    7

    Please Help! - linking opencv

    I think I followed all the instructions to the letter on the wiki pages but I can't even get a hello world running

    I've never used a library that didn't come built in with visual c++ 2010, so I'm guessing I'm linking my project to it wrong??

    Here's what I'm doing in the configuration properties..
    include directories: opencv
    library directories: lib
    source directories: cv , cvaux, cxcore, highgui, ml

    I'm getting these errors

    error LNK2019: unresolved external symbol _cvReleaseImage referenced in function _wmain
    error LNK2019: unresolved external symbol _cvDestroyWindow referenced in function _wmain
    error LNK2019: unresolved external symbol _cvWaitKey referenced in function _wmain
    error LNK2019: unresolved external symbol _cvShowImage referenced in function _wmain
    error LNK2019: unresolved external symbol _cvNamedWindow referenced in function _wmain
    error LNK2019: unresolved external symbol _cvLoadImage referenced in function _wmain

  2. #2
    Registered User Swarvy's Avatar
    Join Date
    Apr 2008
    Location
    United Kingdom
    Posts
    195
    I have no direct experience of using OpenCV, although know people who have. Have you tried looking at this guide: OpenCV tutorial. It is specifically directed at those developing in MS Visual so it may give you some in sight. Sorry I can't be more helpful, but by the looks of the error messages you stated you are not compiling with the right libraries attached.

    Someone with more direct experience of OpenCV may be able to help you more.

  3. #3
    Registered User
    Join Date
    Sep 2010
    Posts
    7

    new problem!

    kk so my problem was with compiling the library first. Be sure to use CMake!

    I have a new problem though.

    I'm getting an application error box: "The application was unable to start correctly" some hex and "Click OK to close the application"

    From what I'm seeing on other boards and blogs, it's because I'm running x64 windows 7. I'm using visual c++ 2010, too if that makes any difference.

    If anyone has seen and conquored this error, please help!

  4. #4
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,851
    Being more specific than "some hex" would be helpful.

    Googling the "some hex" would show you all the other people who had the same error as well, and maybe even something on one of the microsoft sites.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  5. #5
    Registered User
    Join Date
    Sep 2010
    Posts
    7

    hex

    the hex coming up with the error is 0xc0150002

    I googled this error (including the hex) and found a few other people having the same problem, but no solutions so far.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Compiling GNU MP
    By mattnp12 in forum C Programming
    Replies: 3
    Last Post: 06-23-2011, 04:58 PM
  2. Linking errors
    By Zeeshan in forum C++ Programming
    Replies: 1
    Last Post: 02-22-2009, 02:10 AM
  3. opencv thread safe?
    By mynickmynick in forum C Programming
    Replies: 3
    Last Post: 05-21-2008, 11:01 AM
  4. Problems linking with g++
    By Just in forum Linux Programming
    Replies: 11
    Last Post: 07-24-2006, 02:35 AM
  5. strange linking error -- can not find shared library
    By George2 in forum C Programming
    Replies: 2
    Last Post: 07-10-2006, 11:51 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21