Take picture using webcam from command line

user183906 picture user183906 · Oct 4, 2009 · Viewed 36.9k times · Source

I have a Logitech webcam (QuickCam Pro for Notebooks), and I'd like to take a snapshot using the cam from a command line.

Does it have any command line interface?

If not, is there an API that will allow me to build a command line tool like this?

Answer

Ted Burke picture Ted Burke · Apr 8, 2011

I know this is an old discussion, but maybe you arrived here like I did recently looking for a simple command line app to capture a snapshot image from a webcam in Windows. If so, have a look at the following post on my blog:

http://batchloaf.wordpress.com/2011/04/06/snapz-a-command-line-cam-image-grabber/

It's about a little program called snapz that I've just written to take a snapshot from a USB camera in a batch file. It's really basic - when you run it, it snaps a 640x480 image from the default video capture device (e.g. webcam) and saves it to the current directory. It's free and easy to use.