Mex and digraph in C++

조회 수: 1 (최근 30일)
Lightonz
Lightonz 2019년 1월 31일
답변: Michael Croucher 2020년 8월 27일
does anybody now how to create digraph and point an mxArray in C++ to it? In the doc nothing was stated about graphs, digraphs or tables.sure you could create mxArray pointing to matrices in C++ and do the transformation inside matlab, But isn't there a direct methode?

채택된 답변

Christine Tobler
Christine Tobler 2019년 1월 31일
graph, digraph and table are MATLAB objects (meaning they are implemented as .m files). There is no C++ syntax to access such objects through mex files.

추가 답변 (1개)

Michael Croucher
Michael Croucher 2020년 8월 27일
I discovered this thread while googling for the same question as Lightonz. It appears there is a way to do this now using matlab::engine::MATLABEngine::setProperty and matlab::engine::MATLABEngine::getProperty member functions. Documentation at https://www.mathworks.com/help/matlab/matlab_external/use-matlab-objects-in-mex-functions.html

카테고리

Help CenterFile Exchange에서 Programming에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by