This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English version of the page.

Note: This page has been translated by MathWorks. Click here to see
To view all translated materials including this page, select Country from the country navigator on the bottom of this page.

mxGetImagData (C)

Imaginary data elements in numeric mxArray

mxGetImagData is not available in the interleaved complex API. Use typed, data-access functions instead. For more information, see Compatibility Considerations.

C Syntax

#include "matrix.h"
void *mxGetImagData(const mxArray *pm);


The mxGetImagData function is similar to mxGetPi, except that in C it returns a void *. For more information, see the description for the mxGetData function.

Input Arguments

expand all

Pointer to a MATLAB array, specified as mxArray *.

Output Arguments

expand all

Pointer to the complex data array within an mxArray, specified as void *. Since void pointers point to a value that has no type, cast the return value to the pointer type that matches the type specified by pm. For information on mapping MATLAB types to their equivalent C types, see mxClassID.

If pm is NULL, then the function returns NULL.

Complex Number Support: Yes

Compatibility Considerations

expand all

Not recommended starting in R2018a

Errors starting in R2018a

Introduced before R2006a