Description
A lot of new cheap webcams output their images in Bayer format. According to the driver writers it is not the job of the driver to provide a conversion routine to something like RGB24, this has to be done in the userspace application. I've found a bit of code that converts Bayer to RGB24, I hope this will make it easier to include support for this image format in Motion, as I'm not a coder I don't really understand what it does, hopefully one of you guys will be able to fathom it out. The file is attached.
[Update: Bayer seems to be supported natively under
V4L2]
--
WillCooke - 05 Oct 2004
(entered by
KennethLavrsen transferred from old feature request topic.
Follow up
As motion works with
YUV420P Palette is better to do a conversion from Bayer ( gbrg ? ) to
YUV420P intead of Bayer <-> RGB24 <->
YUV420P . There's some work that seems is working around this issue.
Et61xx51 and Spca5xx kernel modules
*
http://mxhaard.free.fr/download.html ( Download source code ).
SpcaView & SpcaTools Howto
*
http://mxhaard.free.fr/sview.html ( Documentation and examples ).
--
AngelCarpintero - 05 Oct 2004
Description of the Bayer format and how to convert to RGB
*
http://www.siliconimaging.com/RGB%20Bayer.htm
- I would not mind adding it if someone writes it. Not currently being developed by anyone and not on the high priority list for the currently active developers. -- KennethLavrsen - 17 Mar 2005
Supporting bayer would be relativly easy if it was just treated as if it was an black and white Y plane. If that is done the detection would work just fine...
Only when the real image would have to be outputted would it have to be converted and only if the output doesn't understand bayer itself.
(e.g. the vloopback would need no conversion, ffmpeg might not need it and jpeg probably will need it)
--
JeroenVreeken - 04 Apr 2005