Linux support for webcam data streams ??
I have a game project that uses a webcam to read positions off a table surface.
A webcam feeding images to DirectX/DirectShow gives me access to video frames (stills could serve just as well) for the processing needed to determine positions (filtering and using trig or matrix transformation to remove perspective, etc...).
The other person in the project has said that running on Linux would greatly simplify other parts of the project, so my question is: How good is the support to access the same data. The webcam of course has its own interface for configuring itself (some manual camera calibration would be expected).
Does linux have any general 'standard' interfaces available for video (and libs that allow access)???
--------------------------------------------[size="1"]Ratings are Opinion, not Fact
May 17, 2006 01:13 AM
You're looking for V4L (video4linux) or V4L2. The former is more mature and apparently still favored by programmers for various reasons. IIRC, it uses ioctl, making it a bit awkward to use.
Obviously your webcam must be supported by Linux.
Hope this helps.
Obviously your webcam must be supported by Linux.
Hope this helps.
May 17, 2006 01:20 AM
Quote: Original post by wodinoneeye
Does linux have any general 'standard' interfaces available for video (and libs that allow access)???
Sorry, somehow I missed that bit. If by "interfaces", you mean something like a GUI, then no. Linux is just kernel. Even with a userland environment (libc, etc), there is no guarantee that a display will be present at all.
It's quite possible that GNOME and/or KDE would offer such an interface though. If they do, they probably also provide some kind of API to use it, or at least make it available via Bonobo or KParts. I use plain window managers though, so I have no experience with either GNOME or KDE.
Hope this helps.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement