mxGetPr返回什么?

时间:2017-08-10 12:45:26

标签: c++ matlab mex

下面一段代码中mxGetPr(prhs [3])[i]的实际值是多少?

void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
    {
       int *D = new int[100];
       // prhs[3] is a 10x10 matrix containing floating point value

       for (int i=0; i<100; i++)
           D[i] = mxGetPr(prhs[3])[i];
    }

0 个答案:

没有答案