1USB Webcam driver 2(c) 2004,2005,2006 François Revol. 3Parts (c) Be,Inc. (ProducerNode sample code). 4 5Current version of my USB Webcam driver. WORK IN PROGRESS! 6Uses the USB Kit (userland API, needs libusb) to publish a 7media node representing the webcam. 8 9It currently only works with my Sonix webcam (3Euro cheapo 10cam, using an SN9C120 chip), but is modular enough to easily 11expand it, some code is already there to detect Quickcams. 12 13Note however that most webcams only support isochronous 14transfers, so will NOT work in R5 or even Zeta as isochronous 15is mostly not working. That's the reason for only supporting 16my Sonix webcam as it is bulk capable. 17As soon as iso support is added to the USB stack and the 18USB Kit it should be possible to support other webcams quite 19easily. 20 21For now you should be able to build it under Zeta with the 22makefile provided. 23 24Making a Jamfile might get tricky as several source files are 25created by the makefile itself to include addons and censors 26in the build. 27 28There are 3 kinds of device-specific folders : 29addons/ contains actual usb chip support code for each device. 30sensors/ contains code to handle CMOS sensors, as each model 31 of a specific brand usually have a different CMOS chip 32 despite a common usb chip. 33cstransforms/ for colorspace transforms so other device using 34 the same weird colorspace can reuse the code (not yet 35 used, sonix has its own code for now). It should be 36 possible to use Translator-based transforms, making 37 it easy to support webcams sending JPEG pictures. 38 Another option is to turn all cstransforms into actual 39 Translators usable by other apps, or also media codecs 40 but that would be more work for few added value. 41 42Other notes and TODO: 43- finish the bayer cstransform and use that instead of copied 44(MIT) code in Sonix addon. 45- implement handling picture sizes correctly (currently forced 46in the ProducerNode and the Sonix code to 320x240) 47- there are currently 2 Deframer classes, the StreamingDeframer 48although more complex seems to work much better than the 49BufferingDeframer. Make my mind about them. 50- write isochronous code when USB Kit supports it 51- add quickcam support (I have some code around) (requires iso) 52- add code to support Fuji FinePix to merge the FinePix addon 53from bebits ? (need to find one to test) 54- design an extensible API to publish possible controls as 55ParameterWeb or forward ParameterWeb changes right to the 56device-specific addon and provide default handlers for usual 57controls ? 58 59References: 60 61* Sonix linux drivers (several of them): 62http://sourceforge.net/projects/sonix/ -- http://sonix.sourceforge.net/ 63http://freshmeat.net/projects/sonic-snap/?branch_id=55324&release_id=183982 64http://tgnard.free.fr/linux/ 65(datasheet) 66http://www.mnementh.co.uk/sonix/sn9c102.pdf 67 68* Other webcam drivers: 69http://zc0302.sourceforge.net/zc0302.php?page=cams 70http://www.medias.ne.jp/~takam/bsd/NetBSD.html 71 72* CMOS Sensor datasheets (rather, marketing buzz): 73http://www.tascorp.com.tw/product_file/TAS5110C1B_Brief_V0.3.pdf 74http://www.tascorp.com.tw/product_file/TAS5130D1B_Brief_V0.3.pdf 75 76* Linux USB stack: 77http://www.iglu.org.il/lxr/source/include/linux/usb.h 78 79* Linux V4L webcam list: 80http://linuxtv.org/v4lwiki/index.php/Webcams 81 82* Fuji FinePix BeOS driver, should probably be merged at some point: 83http://bebits.com/app/4185 84 85