Increasing camera capture resolution in OpenCV

I’m using openCV 1.1pre1 under Windows (videoinput library is used by default by this version of openCv under windows). With these instructions I can set camera resolution. Note that I call the old cvCreateCameraCapture instead of cvCaptureFromCam. capture = cvCreateCameraCapture(cameraIndex); cvSetCaptureProperty( capture, CV_CAP_PROP_FRAME_WIDTH, 640 ); cvSetCaptureProperty( capture, CV_CAP_PROP_FRAME_HEIGHT, 480 ); videoFrame = cvQueryFrame(capture); I’ve tested … Read more

Capturing image from webcam in java?

This JavaCV implementation works fine. Code: import org.bytedeco.javacv.*; import org.bytedeco.opencv.opencv_core.IplImage; import java.io.File; import static org.bytedeco.opencv.global.opencv_core.cvFlip; import static org.bytedeco.opencv.helper.opencv_imgcodecs.cvSaveImage; public class Test implements Runnable { final int INTERVAL = 100;///you may use interval CanvasFrame canvas = new CanvasFrame(“Web Cam”); public Test() { canvas.setDefaultCloseOperation(javax.swing.JFrame.EXIT_ON_CLOSE); } public void run() { new File(“images”).mkdir(); FrameGrabber grabber = new OpenCVFrameGrabber(0); // … Read more

python pygame.camera.init() NO vidcapture

I met the same problem. The error info of “ImportError: No module named vidcap” indicates that python interpreter didn’t find the vidcap module on you machine. so you’d better follow these steps. Download the vidcap from http://videocapture.sourceforge.net/ 2.Then copy the corresponding version of dll (which named “vidcap.pyd” in VideoCapture-0.9-5\VideoCapture-0.9-5\Python27\DLLs) to “your python path”\DLLs\ . 3.restart … Read more