I'm trying to use the opencv bindings of Python.
I tried the following code:
from opencv.highgui import * from opencv.cv import * cam = 'cam' cvNamedWindow(cam) cap = cvCreateCameraCapture(0) while cvWaitKey(1) != 27: img=cvQueryFrame(cap) cvShowImage(cam,img)
Although the window seems to open fine, I cannot see any image. I just get a window without any image -> as if there is no image stored in variable 'img'
On checking the 'img' variable (using cvSaveImage('test.jpg',img)), I found that the img file was ok (the stoed file was correct).
Any idea what is causing the problem?