MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   MATLAB论坛 (https://www.labfans.com/bbs/forumdisplay.php?f=6)
-   -   [讨论]vb做图形界面时调用matlab语句 (https://www.labfans.com/bbs/showthread.php?t=3879)

xuexizhe 2008-07-11 23:03

[讨论]vb做图形界面时调用matlab语句
 
[SIZE="4"][/SIZE] 我在做一个用matlab和vb做的图像处理软件,我选择的方法是COM连接,
我设置的.m函数是
function result=imagezq(x,i)
x=imread('D1.bmp');
global result;
switch i;
case 1
result=histeq(x);
case 2
result=imadjust(x,[],[0.25 1]);
otherwise
warning('Invild operation');
end
imshow(result);
我在vb中编写的程序是
Public Filename As String
Private thpic As mypic.mypic
Private Sub Form_Load()
Set thpic = New mypic.mypic
End Sub

Private Sub AA1_Click(Index As Integer)
CommonDialog1.ShowOpen
Image1.Picture = _
LoadPicture(CommonDialog1.Filename)
End Sub

Private Sub BB1_Click(Index As Integer)
[COLOR="red"]Call thpic.imagezq(1, result, x, i)[/COLOR]
Image1.Picture = LoadPicture(result)
End Sub

Private Sub BB2_Click(Index As Integer)
[COLOR="Red"]Call thpic.imagezq(1, result, x, i)[/COLOR]
End Sub
调用.m语句时格式错误,请高手
帮忙修改
谢谢谢!:cry:

热心人麻烦将修改后的程序发到邮箱[email protected]更好
万分感谢!


所有时间均为北京时间。现在的时间是 05:22

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.