Matlab Interface to Generic Dlls

大家須要在MATLAB中呼叫或使用dll檔案嗎
在目前的MATLAB6.5 SP1中已加入了這個應用介面
不過可能很多人由MathWorks上下載下來的安裝後都會有一點問題
目前分享的這個東西是更新版
下載後直接解壓縮就可以使用了

There are some limitations and restrictions that must be noted:

1) Currently, the MATLAB Interface to Shared Libraries is supported on Windows systems only. Windows shared library files have the file extension .dll.

2) Passing a void ** argument (that is, a pointer to a VOID pointer) to a function in a shared library is not supported in this release.

3) Passing a complex structure argument (that is, a structure constructed from other structures) to a shared library function is not supported in this release.

4) MATLAB does not currently support manipulation (e.g., addition, subtraction) of pointers returned by functions in a shared library.

help pdf檔的位置:
For more information on how to use MATLAB to load and call shared library functions, and for specifics on data conversion, consult the PDF documentation shipped with the files. It is automatically installed in the $MATLAB/toolbox/matlab/general directory (where $MATLAB is your root MATLAB directory). There are 3 documentation files: dll_interface_guide.pdf, dll_interface_reference.pdf, dll_interface_relnotes.pdf

Examples
This example calls functions from the libmx library to test the value stored in y:

warning off MATLAB:loadlibrary:typenotfound
hfile = [matlabroot '/extern/include/matrix.h'];
loadlibrary('libmx', hfile)

y = rand(4, 7, 2);

calllib('libmx', 'mxGetNumberOfElements', y)
ans =
    56

calllib('libmx', 'mxGetClassID', y)
ans =
   mxDOUBLE_CLASS

unloadlibrary libmx

希望能夠引起大家熱列的討論這個套件


附件

来源:http://www.simwe.com/cgi-bin/ut/topic_show.cgi?id=29664&h=1&bpg=3&age=-1

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值