When I use imshow() the image is shown for 1 camera, but there are strange ascii characters along the top bar instead of the window name...anybody else have this issue? I am using Opencv249, VS2013, Win 8.1 and running 64 bit app
trying stereo camera as well...here is code:
#include "opencv\cv.h";
#include "opencv2\highgui\highgui.hpp";
#include "opencv2\imgproc\imgproc.hpp";
#include <iostream>;
using namespace cv;
using namespace std;
int main()
{
VideoCapture stream1(0); //camera 1
VideoCapture stream2(1); // camera 2
if (!stream1.isOpened()) { //check if video device 0 has been initialised
cout << "cannot open camera";
};
if (!stream2.isOpened()) { //check if video device 1 has been initialised
cout << "cannot open camera";
};
// if (!stream1.isOpened()) return 1;
// if (!stream2.isOpened()) return 1;
for (;;){
// while (true){
Mat cameraFrame1;
Mat cameraFrame2;
stream1.read(cameraFrame1);
stream2.read(cameraFrame2);
namedWindow("RedCamera", WINDOW_AUTOSIZE);
imshow("RedCamera", cameraFrame1);
namedWindow("BlackCamera", WINDOW_AUTOSIZE);
imshow("BlackCamera", cameraFrame2);
if (waitKey(30) >= 0) break;
}
return 0;
}
Any help is appreciated!!