Skip to content Skip to sidebar Skip to footer

Opencv Codecs Under Windows

I followed these instructions to install opencv for python (i.e. copying the pyd file into site-packages). It works fine, except opencv cannot open any video files I try to open: c

Solution 1:

Install the newest FFmpeg available from the repository:

git clone git://source.ffmpeg.org/ffmpeg.git ffmpeg

The version you have installed is probably not compatible with OpenCV 2.4.7. The easiest way to test this hypothesis is to downgrade OpenCV to version 2.4.5.

And remember: cv2.VideoCapture("some_file.avi") will succeed only if some_file.avi is in the same directory as your source code. If that's not the case, you should use the full path to the file!

I want to quote another post from this forum:

The cause of your problem could be bug #2281: VideoCapture::read fails on uncompressed video.

Anyway, please try OpenCV 2.4.5 and let us know if it worked.


Solution 2:

I'm struggling with same issue, I guess (OpenCV 2.4.7 with FFMpeg support build with VS 2010 (x86)). Just to make sure, you tried to open an existing video, including the full path, right?

Best


Post a Comment for "Opencv Codecs Under Windows"