Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8894755
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T23:35:19+00:00 2026-06-14T23:35:19+00:00

I have developed a c++ program which uses OpenCV. Now i want to develop

  • 0

I have developed a c++ program which uses OpenCV. Now i want to develop a windows form based application in C#.
As C# can only handle managed code it is nearly impossible to run OpenCV directly on C# application. I have searched for different ways to create C# application using OpenCV, one of which is EmguCV and the other method that i am much more interested in is importing the c++ .dll file in C# application and calling the unmanaged functions this way.

I started by creating simple functions in c++ and i was able to use cout and cin in my C# application by importing the dll. The problem comes when i try to include OpenCV header files in my c++ application and when i compile i get this error

error LNK1104: cannot open file ‘tbb_debug.lib’

Some one has done this before but i cant figure out how he interface c++ with C# in
Displaying webcam feed in cv::Mat format in a picturebox

The Question is that i have function which takes in a cv::Mat variable and performs some image processing on it and returns the processed matrix. i want to use that function written in c++ in my C# application. but the problem is that i am unable to create the dll when i include OpenCV library in c++.

So please Don’t Suggest me to use EmguCV or any other .NET wrappers
for OpenCV.

i am using Visual Studio 2010 for my Project.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T23:35:20+00:00Added an answer on June 14, 2026 at 11:35 pm

    I would explicitly export methods that wrap your entry points in a C++ header, and then use P/Invoke to reference them:

    extern "C" __declspec(dllexport) BOOL DoSomething();
    

    Then consume them in the C#:

    [DllImport("MyOpenCVWrapper.dll")]
    private static extern bool DoSomething();
    

    I wouldn’t try to reference the OpenCV headers.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have developed a Java Swing application, which uses the SwingWorker class to perform
I have developed a program which uses SQLite 3.7 ... database, in it there
We have a program developed with Vb.net which uses CheckedListBox control and the program
I have developed a .NET desktop application which uses SQL Server 2005 SP3 Express.
i have recently developed a list program in android in which there is an
I have enrolled in the iOS developer's program. I've developed an app which I
This is my code I have developed. This is the main program which holds
We have developed a program which checks our web site to see whether or
I have developed a program in Octave to which I would like to add
I have a program for which I have developed a user guide. I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.