Forum Discussion
Altera_Forum
Honored Contributor
20 years agoClass and C++
Hi everyone, I'm brand new developer with NiosII and C++, and I'm experiencing some problems with NiosII IDE, expecially in building application in C++. I created a classe called "...
Altera_Forum
Honored Contributor
16 years agohello,
I cannot define a class using Nios II IDE environment! the class is defined in basicOCR.h as follow: --- Quote Start --- class basicOCR{ public: float classify(IplImage* img,int showResult); basicOCR (); void test(); private: char file_path[255]; int train_samples; int classes; CvMat* trainData; CvMat* trainClasses; int size; static const int K=10; CvKNearest *knn; void getData(); void train(); }; --- Quote End --- Although "Support C++" is activated, errors occur: --- Quote Start --- ../basicOCR.h: At top level: ../basicOCR.h:25: error: syntax error before "basicOCR" ../basicOCR.h:25: error: syntax error before '{' token ../basicOCR.h:30: error: syntax error before ':' token --- Quote End --- any ideas ? thanks