opencv: VideoCapture cannot open video file in Java
Transferred from http://code.opencv.org/issues/4298
|| Bahramuidn Adil on 2015-04-28 05:17
|| Priority: High
|| Affected: branch 'master' (3.0-dev)
|| Category: java bindings
|| Tracker: Bug
|| Difficulty: Medium
|| PR:
|| Platform: x64 / Windows
VideoCapture cannot open video file in Java
History
Bahramuidn Adil on 2015-04-28 05:20
OpenCV 3.0 VideoCapture doesn't open video file in Java, but there is no problem if open camera.
- Target version set to 3.0
Maksim Shabunin on 2015-04-28 12:35
- Category set to java bindings
About this issue
- Original URL
- State: closed
- Created 9 years ago
- Comments: 18 (3 by maintainers)
You are missing the loading ffmpeg dll. If use 64 add opencv_ffmpeg300_64.dll. If you use 32 add opencv_ffmpeg300.dll. Add this the your code.
System.loadLibrary
is not required. Just putopencv_ffmpeg*.dll
file(s) nearopencv_java*.dll
or update PATH environment variable which should point toopencv_ffmpeg*.dll
Using OpenCV 3.0 on windows:
I have same issue on Ubuntu. I’ve tried to compile ffmpeg from source as shared lib. It creates some libav*.so, but OpenCV Java code still cannot open the mp4/avi file with no errror or warning. What should I do?