Using a .mexw64 in a mexFunction
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Hello,
I've compiled a mexFunction function1.mexw64 and it works perfectly. Now I need this function in another mexFunction of which the compiled version would be function2.mexw64. Is it possible to call a compiled mexFunction in the body of another mexFunction? If yes, how do I do so?
Thanks.
0 Commenti
Risposta accettata
Jan
il 15 Apr 2012
Either insert the C-source of function1.c without the mexFunction gateway to function2.c. Or call function2 through mexCallMATLAB:
mxArray *Input[1];
Input[1] = mxCreate...
mexCallMATLAB(0,NULL,1, Input, "function2");
The later is less efficient due to the double overhead of calling Matlab to call the mex.
0 Commenti
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Write C Functions Callable from MATLAB (MEX Files) in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!