Dear All:
In order to perform a real-time object detection, I connected a Canon digital camera via usb to a Raspberry Pi 2 platform. Then I installed Gphoto2. Now, I got two separate files which are built and perfectly work via two separate builders. However, I cannot combine them for the above purpose; and I want you, experts, to resolve this problem for me, as follows:
1- First one is a C program based file that captures several images and send to the Raspberry Pi. This file is built on Terminal by:
gcc –o filename filename.c –lgphoto2
(Reference: Sepharad's: Camera tethered capturing using libgphoto2 )
2- The second one is a c++ program based file that captures video from a webcam for video analysis by OpenCV. This file is built by CMakeLists.txt.
(References:
Installation in Linux — OpenCV 2.4.12.0 documentation
Using OpenCV with gcc and CMake — OpenCV 2.4.12.0 documentation )
I need to have a single file capable of both abovementioned jobs, except I need video (GP_CAPTURE_MOVIE) rather a sequence of images. The operating system is Debian Jessie.
(References: libgphoto2 photo camera library (libgphoto2) API: gphoto2/gphoto2-camera.h File Reference ).
Thank you in advance.
Cheeeers.