PDA

View Full Version : Install opencv on ubuntu error, please help



cooper
9th July 2009, 23:55
hi,

i tried to install opencv on my ubuntu system follow by:
http://opencv.willowgarage.com/wiki/InstallGuide_Linux

i got two errors when i tried to use "make" to build the library:


/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp: In member function ‘virtual IplImage* CvCapture_FFMPEG::retrieveFrame(int)’:
/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp:549: error: ‘img_convert’ was not declared in this scope
/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp: In member function ‘virtual bool CvVideoWriter_FFMPEG::writeFrame(const IplImage*)’:
/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp:1044: error: ‘img_convert’ was not declared in this scope
/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp: In member function ‘virtual bool CvVideoWriter_FFMPEG::open(const char*, int, double, CvSize, bool)’:
/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp:1180: warning: ‘AVFormatContext* av_alloc_format_context()’ is deprecated (declared at /usr/include/libavformat/avformat.h:873)
/home/cz/Webcam/trunk/opencv/src/highgui/cvcap_ffmpeg.cpp:1180: warning: ‘AVFormatContext* av_alloc_format_context()’ is deprecated (declared at /usr/include/libavformat/avformat.h:873)
make[2]: *** [src/highgui/CMakeFiles/highgui.dir/cvcap_ffmpeg.o] Error 1
make[1]: *** [src/highgui/CMakeFiles/highgui.dir/all] Error 2
make: *** [all] Error 2


i googled a whole day yesterday, it seen like that ffmpeg recently change their file structure, but opencv did not follow the change.

how can i solve the problem? can anyone help me, please?
thanks in advance.

jpn
15th July 2009, 20:40
Remember that you are not limited to the ffmpeg package provided in the official Ubuntu repositories. How about downloading a compatible version, compiling and installing it yourself?

ber0y
16th July 2009, 12:46
hi,
i tried to install opencv on my ubuntu system follow by:
http://opencv.willowgarage.com/wiki/InstallGuide_Linux


Use Synaptic it's so easier