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 664245
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 13, 20262026-05-13T23:34:43+00:00 2026-05-13T23:34:43+00:00

I am working on a project that requires some image processing. The front end

  • 0

I am working on a project that requires some image processing. The front end of the program is C# (cause the guys thought it is a lot simpler to make the UI in it). However, as the image processing part needs a lot of CPU juice I am making this part in C++.

The idea is to link it to the C# project and just call a function from a DLL to make the image processing part and allow to the C# environment to process the data afterwards. Now the only problem is that it seems I am not able to make the DLL. Simply put the compiler refuses to put any function into the DLL that I compile.

Because the project requires some development time testing I have created two projects into a C++ solution. One is for the Dll and another console application. The console project holds all the files and I just include the corresponding header into my DLL project file. I thought the compiler should take out the functions that I marked as to be exported and make the DLL from them. Nevertheless this does not happens.

Here it is how I defined the function in the header:

extern "C" __declspec(dllexport)  void _stdcall RobotData(BYTE* buf, int** pToNewBackgroundImage, int* pToBackgroundImage,  bool InitFlag, ObjectInformation* robot1, ObjectInformation* robot2,   ObjectInformation* robot3, ObjectInformation* robot4,  ObjectInformation* puck);

extern "C" __declspec(dllexport)  CvPoint _stdcall RefPointFinder(IplImage* imgInput, CvRect &imgROI, 
                         CvScalar &refHSVColorLow, CvScalar &refHSVColorHi );

Followed by the implementation in the cpp file:

extern "C" __declspec(dllexport)  CvPoint _stdcall RefPointFinder(IplImage* imgInput, CvRect  &imgROI,&refHSVColorLow, CvScalar &refHSVColorHi ) { \\...
                  return cvPoint((int)( M10/M00) +  imgROI.x, (int)( M01/M00 ) +  imgROI.y) ;}

extern "C" __declspec(dllexport)  void _stdcall RobotData(BYTE* buf, int** pToNewBackgroundImage, int* pToBackgroundImage,  bool InitFlag, ObjectInformation* robot1, ObjectInformation* robot2,   ObjectInformation* robot3, ObjectInformation* robot4,  ObjectInformation* puck) { \\ ...};

And my main file for the DLL project looks like:

#ifdef _MANAGED
#pragma managed(push, off)
#endif

/// <summary> Include files.  </summary>
#include "..\ImageProcessingDebug\ImageProcessingTest.h"
#include "..\ImageProcessingDebug\ImageProcessing.h"


BOOL APIENTRY DllMain( HMODULE hModule, DWORD  ul_reason_for_call, LPVOID lpReserved)
{
 return TRUE;
}

#ifdef _MANAGED
#pragma managed(pop)
#endif

Needless to say it does not work. A quick look with DLL export viewer 1.36 reveals that no function is inside the library. I don’t get it. What I am doing wrong ?
alt text

As side not I am using the C++ objects (and here it is the C++ DLL part) such as the vector. However, only for internal usage. These will not appear in the headers of either function as you can observe from the previous code snippets.

Any ideas? Thx,

Bernat

  • 1 1 Answer
  • 1 View
  • 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-05-13T23:34:43+00:00Added an answer on May 13, 2026 at 11:34 pm

    It seems you are confused about which files to include in your DLL project vs your console project. If it is true that “The console project holds all the files” then this is your problem.

    Your DLL project needs to include the cpp file which has the __declspec(dllexport)s. As you describe it, you have included your RefPointFinder() & RobotData() functions in the console project. In other words your DLL has no functions in it whatsoever, regardless of whether anything is exported.

    Just including the .h files in the DLL main file does nothing by itself. It doesn’t include these functions in the DLL.

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

Sidebar

Ask A Question

Stats

  • Questions 410k
  • Answers 410k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer You will need to execute the .sql file in Sql… May 15, 2026 at 7:30 am
  • Editorial Team
    Editorial Team added an answer Firstly your question seems to touch on two topics, full… May 15, 2026 at 7:30 am
  • Editorial Team
    Editorial Team added an answer You can directly select only the distinct dates from the… May 15, 2026 at 7:30 am

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.