C++ TO MATLAB

3 ビュー (過去 30 日間)
Ahil Khan
Ahil Khan 2020 年 10 月 27 日
回答済み: Nitin Kapgate 2020 年 10 月 30 日
Hello! I wanted to find out, how can I convert c++ code to MATLAB? Is it possible? And if so, what are the steps? Regards.

回答 (1 件)

Nitin Kapgate
Nitin Kapgate 2020 年 10 月 30 日
If your goal is to convert C++ code to MATLAB code, manual conversion is required.
However, if you only need to call the C++ code from MATLAB, simpler solutions are possible:
  • Option A: create a MEX file via MATLAB Coder (using MATLAB Coder on a simple M file that just calls the C++ function using coder.cinclude and coder.ceval) - see the last comment on a similar question.
  • Option B: create a MEX file via the MEX command (you will need to write a MEX wrapper for the C++ code). More information can be found on this documentation page.
You can also refer the guide for Using MATLAB with C and C++ .

カテゴリ

Help Center および File ExchangeCall C++ from MATLAB についてさらに検索

タグ

製品


リリース

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by