开发者

convert C structure to matlab structure

开发者 https://www.devze.com 2023-01-29 06:08 出处:网络
i want to ask if there is a simple method to convert C/C++ structure toa MATLAB structure (mxArray*)

i want to ask if there is a simple method to convert C/C++ structure to a MATLAB structure (mxArray*)

i have a mex file which returns a complex C/C++ structur开发者_运维知识库e of vectors and i want to get this as output (mxArray*)

i found the mxCreateStructArray method but its not practical in a complex structures

i am using MATLAB 7.11.0


No, there is not such simple method. You need to use mxCreateStructArray, mxAddField, etc methods and create the Matlab struct field by field.

http://www.mathworks.com/matlabcentral/newsreader/view_thread/239457

0

精彩评论

暂无评论...
验证码 换一张
取 消