For me on Windows 8.1 it helped:
- to use DLLs inside installation package: sources/3rdparty/ffmpeg (opencv_ffmpeg.dll and opencv, _ffmpeg_64.dll)
- copy them to c:\Python27 directory and rename them accordingly to openCV version used.
for openCV 2.4.10
- opencv_ffmpeg2410.dll
- opencv_ffmpeg2410_64.dll
for openCV 3.0.0 beta
- opencv_ffmpeg300.dll
- opencv_ffmpeg300_64.dll