I’m trying to acquire video from a DCAM1394 camera using OpenCV (C++) on Win 7 (64bit). I tried VideoCapture, but it seems only works on webcam instead of the firewire camera. Then I found a thread; following its idea, I installed the CMU1394 driver for my firewire camera, and tried to recompile opencv.
Below is How I did it:
STEP1: Install the CMU1394 driver by running the file 1394camera646.exe, and then run the demo provided by the publisher; it worked just fine, which I think proves that the driver has been installed successfully.
STEP2: Then I open the file "{where you extract opencv}...\sources\modules\highgui\src\cap_cmu.cpp" (as shown in the Fig), and add "#def HAVE_CMU1394 1" right before "#ifdef HAVE_CMU1394", in hope of letting the codes after "#ifdef HAVE_CMU1394" to be compiled.
STEP3: After the revision of "cap_cmu.cpp", I configure and generate files from source using Cmake, and compile the output using VS2013 Express. Here an error popped up: "cannot open include file "1394camera.h"".
Normally, the file "1394camera.h" is not precompiled in OpenCV by default; the error popped up due to adding "#def HAVE_CMU1394 1" before "#ifdef HAVE_CMU1394" (which is exactly what I want to do). OpenCV source doesn't have the file "1394camera.h", and it is provided by the CMU1394 in its source file 1394camera646_src.
So, my question is:
1) Am I conducting the right procedure by "Install CMU1394 -> Recompile OpenCV"?;
2) I know that the recompiling fails because the compiler cannot find "1394camera.h". But How can I include that file (and other .h/.cpp files in 1394camera646_src) in OpenCV source file and compile them together?