Is there anyway to check what functions are defined in a mex file?

조회 수: 7 (최근 30일)
Suganthan
Suganthan 2015년 4월 9일
댓글: James Tursa 2015년 4월 10일
Hi,
I used dependency walker to open a mex file, but can't see the function list. Is there a tool or anyway to check the function list for a mex file? Thanks.
Li

답변 (1개)

Philip Borghesani
Philip Borghesani 2015년 4월 10일
By definition A standard mex file only only has one function available to MATLAB named the same as the mex file and implemented in the function mexFunction.
It is possible to load a mex file as a standard shared library with loadlibrary and call any exported function in it but mex files that have been designed to do this are very rare if any exist at all. If that was the case then dependency walker would show the exported functions.
  댓글 수: 1
James Tursa
James Tursa 2015년 4월 10일
@Suganthan: To expand on what Philip is telling you, mex routines that are built through the standard method (e.g., using mex at the command line) have only one exported function, namely "mexFunction". And that function has (mxArray *)[ ] types in the argument list. So there really isn't anything there for you to call using loadlibrary. It only makes sense to call it as a regular mex function.

댓글을 달려면 로그인하십시오.

태그

Community Treasure Hunt

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

Start Hunting!

Translated by