Video for Linux
Extract from V4L-DVB wiki: The V4L API is essentially a kernel interface for analog video capture and output drivers, and is applicable to most video streams that are not related to DVB devices ... or graphics cards -- though, the V4L API also entails a few oddities such as analog radio and RDS services. Examples of devices which fall within the scope of V4L are, amongst others, webcams, MPEG encoders/decoders, digital video streamers, analog TV tuners and video capture devices.
- V4L comes with a test driver called vivi that can be used to test your V4L applications:
<M> Virtual Video Driver
# modprobe vivi Linux video capture interface: v2.00 vivi: V4L2 device registered as /dev/video0 Video Technology Magazine Virtual Video Capture Board ver 0.5.0 successfully loaded.
- in target/demos/camera/ you will find a test application capture (derived from http://linuxtv.org/downloads/video4linux/API/V4L2_API/v4l2spec/capture.c)
- to compile it (you will need SDL previously installed):
$ make shell_env $ source armadeus_env.sh $ cd target/demos/camera/capture/ $ make CC=$ARMADEUS_TOOLCHAIN_PATH/arm-linux-gcc
- you can also compile it for your Host if needed:
$ cd target/demos/camera/capture/ $ make clean $ make
- to use it, copy capture executable (ARM one) to your board and then launch (here for example with a 800x480 LCD):
# ./capture --width 800 --height 480 --cam_width 640 --cam_height 480