This feels a lot like finding a needle in a hay stack but here goes.
I'm building a Windows Mobile 6.1 application. Specifically I'm trying to port over the OpenCV framework. Having successfully (doubtfully) compiled OpenCV for the ARM4I architecture, I'm trying it out in a simple hello world style application.
From my WinCE .EXE I'm calling a function stored in an OpenCV .DLL (cxcore200.dll). The simple call looks like this.
IplImage *src = cvCreateImage(cvSize(320,240), 8, 1);
Major problems arise when I step into cvCreateImage. The method signature is:
IplImage * cvCreateImage( CvSize size, int depth, int channels ){ ... }
So when I step into this function, depth and size params are equal to 320 and 240 respectively (not 8 and 1 as expected).
For reference, CvSize is declared as:
typedef struct
{
int width;
int height;
}
CvSize;
This is clearly some sort of call stack corruption that has to do with the fact that I'm crossing boundaries into possibly an incorrectly compiled DLL.
Both the DLL and EXE compile and link without errors. Has anybody ever seen anything like this? Any ideas on how to debug this?