Passing Matlab function pointers as arguments to Matlab functions which are called from C
조회 수: 5 (최근 30일)
이전 댓글 표시
Hi,
Hopefully this is possible. I've created two dll's from two m-files; let's call then Funct1.dll and Funct2.dll.
I'm trying to pass Funct1 as a function pointer to funct1--that is, Funct1 is an argument of Funct2. And, Funct2 is called from a C/C++ application. So, my pseudo code is:
//C/C++ application
...
int main()
...
mlfFunt(mlfFunct1, <param2>, <param3>, ...)
//where mlfFunct1 and mlfFunct2 have corresponding
//Funct1.dll and Funct2.dll's compiled from m-file functions
...
return 0;
I keep getting a C/C++ compiler error that "cannot convert parameter <#> from bool ...
I assume that this is because the Matlab m-file function compiled to a dll always returns a bool?
Am I going in the correct direction? Or is there an alternative/better method?
Thanks for efforts.
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 MATLAB Compiler SDK에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!