Is it possible to keep Matlab objects as mxArray type in C++ application ?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Hi,
i am planning on writing an application in C++ and i want to use certain Matlab functions as a .dll that can be compiled with the mcc. Further more i want to make use of objects implemented in Matlab, that i want to pass from one Matlab dll function to another. But therefore i need to store it in an mxArray, or something that the calling application can handle. Is that possible and how would it be done ? So more general, how can Matlab objects be used in C++ ? Sorry if the question is not very detailed, but i am at a very early stage, and just want to check out the possibilities. Any hint will be greatly appreciated. Thanks in advance, ...
0 Commenti
Risposta accettata
James Tursa
il 18 Feb 2016
Modificato: James Tursa
il 18 Feb 2016
How do you plan on calling the MATLAB functions? With the Engine API interface? If so, then as long as you build the application properly with the API library links you should be able to create & store mxArray objects for your eventual MATLAB function calls via the Engine. E.g., see this link:
Note, however, that using a MATLAB Engine will cause deep copies of the mxArray variables whenever you pass arguments to the Engine and retrieve the results.
Più risposte (0)
Vedere anche
Categorie
Scopri di più su C Shared Library Integration in Help Center e File Exchange
Prodotti
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!