请问这个程序哪里错了...

ly08n23 ly08n23 墨衍会员 · AI 创作全网分发 墨衍智能分发 通过墨衍一键同步至各平台 可同步平台 CSDN微信公众号微博知乎掘金百家号博客园抖音小红书 你的文章也可以这样分发 墨衍会员 ¥399起/年,写一次发全网 我也要 + 加入社区
#include "stdafx.h"
#include "cv.h"
#include "cxcore.h"
#include "highgui.h"
#include "disjoint-set.h"
#include <algorithm>
#include <vector>
using namespace System;
using namespace std;
#define width 512
#define height 512
#define cons 300//k
#define THRESHOLD(size, c) (c/size)

struct edgenode
{
int weight;
long int begin,end;
bool operator <(const edgenode& other) const
{
return weight<other.weight;
}
};
vector<edgenode> edge;
int colors[width*height];

int main(array<System::String ^> ^args)
{
edgenode a;
//nodevetex b;
IplImage *pImg,*fImg;
IplImage *newImg;
long int i,j,s,t;

fImg=cvLoadImage("ff.jpg",0);

if(!fImg){
printf("cannot load the file.\n");
return -1;
}

这是程序的一部分。
编译时using namespace System报错,
System:does not exit or is not a namespace


int main(array<System::String ^> ^args) 报错
array:undeclared identifier
System:is not a class or namespace name
String:undeclared identifier
syntax error :'>'


求高手指教。

...全文
评论 9
收藏 已收藏
分享
返回顶部
ly08n23
C++ 语言 65,214 成员 250,514 内容