pwc
[Top] [All Lists]

[pwc] Using v4l2 gives grey images

To:
Subject: [pwc] Using v4l2 gives grey images
From: Niclas Anderberg <>
Date: Wed, 29 Jun 2005 17:01:33 -0700
I am trying to use the latest driver version (10.0.7a) using v4l2. I have written my own sample app which reads frames from the camera and writes jpeg images.

I am getting images fine, but they are somehow grey scale. When I do my colorspace conversion I assume the output is planar, as per the "v4l2 video image format specification". I.e. first imagesize bytes of Y data then imagesize / 4 bytes of U data and finally imagesize / 4 bytes of V data.

When I query the driver for which format it uses (after I've tried to set it differently :), it says V4L2_PIX_FMT_YUV420. If I inspect the U and V values in the image I got from the camera, they are close to 128 in both U and V (i.e. the image is grey).

If I use an app like camE (which I assume uses v4l and v4l2) I get color fine. Is there a restriction in the v4l2 driver that I don't know about? Does anyone have some simple sample code which gives you color images? Any other ideas?

Thanks!
Niclas

_______________________________________________
pwc mailing list

http://lists.saillard.org/mailman/listinfo/pwc

<Prev in Thread] Current Thread [Next in Thread>
Admin

Disclaimer: Neither Andrew Taylor nor the University of NSW School of Computer and Engineering take any responsibility for the contents of this archive. It is purely a compilation of material sent by many people to the birding-aus mailing list. It has not been checked for accuracy nor its content verified in any way. If you wish to get material removed from the archive or have other queries about the archive e-mail Andrew Taylor at this address: andrewt@cse.unsw.EDU.AU