Commit 7dce2d0b authored by StevenPuttemans's avatar StevenPuttemans

fixing cap_pvpapi interface and making sure both AVT Manta and Proscilla

series are supported. Testing this with both cams for Windows and Linux
exhaustively.

Optimizing memory footprint by removing unused calls.

Adapted with the input of Shai

Added small example that illustrates how it should work.
parent a77a2f35
This diff is collapsed.
//////////////////////////////////////////////////////
// Sample illustrating the use of the VideoCapture //
// interface in combination with PvAPI interface //
// //
// Succesfully tested on Prosilica and Manta series //
//////////////////////////////////////////////////////
#include <iostream>
#include "opencv2/opencv.hpp"
using namespace std;
using namespace cv;
int main()
{
// Capturing multiple AVT cameras can be done by simply initiating
// two VideoCaptures after eachother.
VideoCapture camera1(0 + CV_CAP_PVAPI);
VideoCapture camera2(0 + CV_CAP_PVAPI);
Mat frame1, frame2;
for(;;){
camera1 >> frame1;
camera2 >> frame2;
imshow("camera 1 frame", frame1);
imshow("camera 2 frame", frame2);
int key = waitKey(10);
if(key == 27){
break;
}
}
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment