C++ on MATLAB editor
5 次查看(过去 30 天)
显示 更早的评论
Hello All!
I'm looking for a way that: How can I write a C++ code on the MATLAB editor (instead I will write the script in m-file editor).
Is there anyone here who knows how can I do this?
Thanks Morris.
0 个评论
采纳的回答
Walter Roberson
2014-3-15
The editor doesn't care what you write in it. You might want to turn off syntax checking through.
0 个评论
更多回答(1 个)
Morris
2014-3-15
编辑:Morris
2014-3-15
1 个评论
Walter Roberson
2014-3-15
You could consider calling "mex". Use the -c option if you want to compile an individual .cc or .C file to object code. mex normally creates what is really a DLL. If you want to build a complete .exe from the C++ you could system() the linking call after everything is compiled.
Or you could just system() the compilation call directly.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 C Shared Library Integration 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!