Viewing a V4L2 webcam with mplayer

The great mplayer can be used to view movies, play dvd's, and even to watch the webcam. For my Logitech QuickCam Pro 4000, I use the following command:
mplayer -cache 128 -tv driver=v4l2:width=640:height=480:outfmt=i420 -vc rawi420 -vo xv tv://

If you have multiple v4l2 devices, you can choose which device you want to use by adding 'device=/dev/videoX' to the options:
mplayer -cache 128 -tv driver=v4l:width=640:height=480:outfmt=i420:device=/dev/video1 -vc rawi420 -vo xv tv://

© GeekLabInfo Viewing a V4L2 webcam with mplayer is a post from GeekLab.info. You are free to copy materials from GeekLab.info, but you are required to link back to http://www.geeklab.info

1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 2.50 out of 5)
Loading...