需要关于设置matlab以访问外部c++;编译程序

需要关于设置matlab以访问外部c++;编译程序,matlab,visual-c++,mex,sift,winapi,Matlab,Visual C++,Mex,Sift,Winapi,我目前正在学习SIFTGPU matlab教程,并停留在这一早期部分: SIFTGPU在C++中编码,必须保存为.MEX(Matlab外部) 文件,然后才能从Matlab调用它。为了创建.mex 文件,您必须确保Matlab已设置为访问外部 通过输入 C++编译器 mex–设置 进入Matlab命令窗口并按照屏幕上的 指示 因为我没有VisualC++的Express 2010和Windows SDK,所以我在 两个软件的安装都很好,但是,对于matlab: >> mex -set

我目前正在学习SIFTGPU matlab教程,并停留在这一早期部分:

SIFTGPU在C++中编码,必须保存为.MEX(Matlab外部) 文件,然后才能从Matlab调用它。为了创建.mex 文件,您必须确保Matlab已设置为访问外部 通过输入

C++编译器 mex–设置

进入Matlab命令窗口并按照屏幕上的 指示

因为我没有VisualC++的Express 2010和Windows SDK,所以我在

两个软件的安装都很好,但是,对于matlab:

>> mex -setup

Welcome to mex -setup.  This utility will help you set up  
a default compiler.  For a list of supported compilers, see  
http://www.mathworks.com/support/compilers/R2011a/win64.html 

Please choose your compiler for building MEX-files: 

Would you like mex to locate installed compilers [y]/n? y

Select a compiler: 
[1] Microsoft Visual C++ 2010 Express in D:\VS2010 

[0] None 

Compiler: 1

Please verify your choices: 

Compiler: Microsoft Visual C++ 2010 Express  
Location: D:\VS2010 

Are these correct [y]/n? y

***************************************************************************** 
  Error: Microsoft Visual C++ 2010 Express requires the Microsoft Windows 
         Software Development Kit (SDK), but the SDK cannot be found.  
         For more information about the required SDK, see:  
         http://www.mathworks.com/support/compilers/R2011a/win64.html 
***************************************************************************** 

??? Error using ==> mex at 208
Unable to complete successfully.

我不知道下一步该去哪里。有人能告诉我在安装VC++Express 2010和Windows SDK之后接下来需要做什么吗

不要安装Visual Studio Express。安装-它附带了一个编译器,该安装程序可与MATLAB一起使用。Visual Studio也不适用于我,因为您需要运行批处理文件来设置环境,但这些批处理文件存在一些问题

编辑这是安装SDK后的mex配置屏幕:

mex-设置

欢迎使用mex-setup。此实用程序将帮助您设置
默认编译器。有关支持的编译器的列表,请参见

请选择用于生成MEX文件的编译器:

是否希望mex定位已安装的编译器[y]/n?y

选择一个编译器:

[1] C:\Program Files(x86)\Microsoft Visual Studio 10.0中的Microsoft软件开发工具包(SDK)7.1

[0]无

编译器:


@Karl和您一样,键入
mex-setup
并选择windows编译器。只是不要安装VC++Express。只安装SDK-那里有一个编译器。不,根本没有列出任何编译器。@Karl这很奇怪。我已经更新了答案,向您展示了我得到的配置选项。我不是Windows专家,但也许你在某个陌生的地方安装了它?或者您选择了不同的安装选项?你在哪里安装的?在“开始”菜单中看到了吗?…等等。您有C:\ProgramFiles(x86)\Microsoft Visual Studio 10.0吗?我记得你说过“不要安装Visual Studio”。为什么会在那里?@Karl这是SDK的一部分。我说过你不应该安装VisualStudioExpress,只应该安装带有编译器的SDK。