Hi, I'm wondering if it's possible to have a class constructor be fully written in MEX? My first thought was to call the "class" function via mexCallMATLAB, and returning the resulting mxArray, however, I see in the documentation [1] that "Outputs of mexCallMATLAB have temporary scope and are automatically destroyed at the end of the MEX function call", so I don't believe this works.
Any ideas?
Thanks
Best Answer