Difference between revisions of "Video for Linux"

From ArmadeusWiki
Jump to: navigation, search
(Page creation)
 
m (Capture)
 
(4 intermediate revisions by the same user not shown)
Line 7: Line 7:
  
 
==Test==
 
==Test==
 +
===Vivi driver===
 
* V4L comes with a test driver called ''vivi'' that can be used to test your V4L applications:
 
* V4L comes with a test driver called ''vivi'' that can be used to test your V4L applications:
 +
<pre class="config">
 +
<M>  Virtual Video Driver
 +
</pre>
 
<pre class="apf">
 
<pre class="apf">
 
# modprobe vivi
 
# modprobe vivi
Line 15: Line 19:
 
</pre>
 
</pre>
  
* in ''target/demos/camera/'' you will find a test application (derived from http://linuxtv.org/downloads/video4linux/API/V4L2_API/v4l2spec/capture.c)
+
===Capture===
 +
* 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):
 +
<pre class="host">
 +
$ make shell_env
 +
$ source armadeus_env.sh
 +
$ cd target/demos/camera/capture/
 +
$ make CC=$ARMADEUS_TOOLCHAIN_PATH/arm-linux-gcc
 +
</pre>
 +
* you can also compile it for your Host if needed:
 +
<pre class="host">
 +
$ cd target/demos/camera/capture/
 +
$ make clean
 +
$ make
 +
</pre>
 +
* to use it, copy ''capture'' executable (ARM one) to your board and then launch (here for example with a 800x480 LCD):
 +
<pre class="apf">
 +
# ./capture --width 800 --height 480 --cam_width 640 --cam_height 480
 +
</pre>
 +
 
 +
==Going further==
 +
* [[Camera interface|Using the camera interface (CSI) of the i.MX]]
 +
* [[USB Webcams| Using USB webcams]]
  
 
==Links==
 
==Links==
 
* [http://www.linuxtv.org/wiki/index.php/Main_Page V4L-DVB Wiki]
 
* [http://www.linuxtv.org/wiki/index.php/Main_Page V4L-DVB Wiki]
 +
 +
[[Category:Video]]
 +
[[Category:Vision]]
 +
[[Category:Linux drivers]]

Latest revision as of 17:55, 9 November 2010

Page under construction... Construction.png Informations on this page are not guaranteed !!

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.

Installation

V4L core drivers are by default installed on APF27 configurations. APF9328 is currently not able to handle V4L compatible image capture streams.

Test

Vivi driver

  • 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.

Capture

$ 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

Going further

Links