ffmpeg - VideoCapture is not working in OpenCV 2.4.2 -
I recently installed OpenCV 2.4.2 in Ubuntu 12.04.
CAP = Video Capture (0) is working but I can not take frames from some video source.
cap = videocapture ("input.avi") img = cap.read () gives me an oval with all the zeros elements.
I have also installed ffmpeg 0.11, the latest snapshot of x264, v4l-0.8.8 (all the latest stable versions)
Cmake -D with_qt = ON -D With_FFMPEG = ON -D WITH_OPENGL = ON -D WITH_TBB = ON-DE BUILD_EXAMPLES = OFF WITH_V4L = ON. SUDO INSTALL When I cmake, I get it
- GNU GCC detected version: 46 (406)
- OpenXR found: /usr/lib/libIlmImf.so
- Discovery of Linux / Videodev.h
- Linux Looking for / videodev.h - Not found - Search for Linux / videodev2.h - Search for linux / videodev2.h - Found - Libavformat / a Looking for vformat.h - looking for libavformat / avformat.h - is found - search for ffmpeg / avformat.h - looking for ffmpeg / avformat.h - not found -> not found -> Check for module 'TBB' - Package 'TBB' not found E
and
- Video I / O: - DC1394 1. X: No - DC1394 2.x: Yes (see 2.2.0) - FFMPEG: Yes - Codec: Yes (ver 54.23.100) - Format: Yes (ver 54.6.100) - Usage: Yes (Works 51.54.100) - Swaschellah: Yes (see 2.1.100) - Gentle-style: Yes - Gistemar: - Base: Yes (V. 0.10.36) - App: Yes (V. 0.10 .36) - Video: Yes (Vertical 0.10.36) - OpenNi: No - Open NI Prime Sensor Module: No - PVAPI: No - Unip: No - Unipap ucil: No - V4L / V4L2: Live4 Use of L (see 0.8.8) - XMaya: No - SIN: No I looked for videodev.h, etc.
- / usr / Include / linux / videodev2.h exists
- the /usr/include/libavformat/avformat.h exists
- the /usr/local/include/libavformat/avformat.h exists < / Li>
but I did not find ffmpeg / avformat.h What is the problem here?
So, I realized there was some problem with ffmpeg. And I made and re-created ffmpeg and then changed the flags to cmake to create opencv.
For ffmpeg,
.configure --enable-gpl --enable-libfaac - -enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore -amrwb --enable-libtheora --enable-libvorbis --enable-libx264 --enable-libxvid --enable-nonfree --enable-postproc - for OpenCV cmake -d CMAKE_BUILD_TYPE = To release sudo install-version 3 - enabled - < / P>
Comments
Post a Comment