win7 64位系统 VS2010 MATLAB2013 混合仿真
C#程序段:
using MathWorks;
using MathWorks.MATLAB.NET.Utility;
using MathWorks.MATLAB.NET.Arrays;
using MLApp;
using pic1;
namespace PictureShow1
{
public partial class Form1 : Form
{
public Form1()
{
InitializeComponent();
}
private void button1_Click(object sender, EventArgs e)
{
pic1.picClass1 PC1 =new pic1.picClass1( );
// PC1.PicShow1();
string path="D:/Documents/MATLAB/myAdd/test1.bmp";
Bitmap image = new Bitmap(path);
pictureBox1.Image = image;
PC1.PicShow1(path);
}
}
}
MATLAB程序段:
function [I2]=PicShow1(path)
I=imread(path);
I1=rgb2gray(I);
I2=im2bw(I1);
imshow(I2);
saveas(gcf,'E:\pic1.bmp');
end
报错显示,求高手指点:
我也遇到了同样的问题,是你.m函数里调用了MATLAB的其他库函数,但这库函数不是核心函数,不被mcr包含。所以出错
请问具体要怎么解决啊~拜托了
请问是怎么解决的呢?万分感谢!