Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.


From Wiki
Jump to: navigation, search
Article Metadata
Created: xharada (10 Feb 2009)
Last edited: hamishwillee (31 Jul 2012)


This article is about using "Video for Linux" on maemo and requires some knowledge of maemo as this is a fairly in-depth article using Linux port.


Video4linux – V4L (Video for Linux) is an API that offers access to capture devices such as web-cams, video/TV cards, radio cards, and others. Nowadays it is in its second version (V4L2 – Video for Linux 2). V4L/V4L2 are both integrated with latest Linux Kernels, therefore, with maemo distribution.

Basically, V4L/V4L2 work sending predefined structures to opened Linux devices. For example, the following code snippet shows how to retrieve capabilities from a specific device:

#define DEFAULT_DEVICE "/dev/video0"
//V4L Structure
struct v4l2_capability vc;
//Open the device, for example /dev/video0, or /dev/radio0
int fd = open(DEFAULT_DEVICE, O_RDONLY);
//Send structure to the opened device using V4L2 API
ioctl(fd, VIDIOC_QUERYCAP, &vc);

External links

This page was last modified on 31 July 2012, at 10:20.
55 page views in the last 30 days.

Was this page helpful?

Your feedback about this content is important. Let us know what you think.


Thank you!

We appreciate your feedback.