[libavg-devel] v4l branch code review

Ulrich von Zadow uzadow at libavg.de
Fri Aug 3 17:15:11 CEST 2007


Hi,

I just merged everything to trunk :-).

I'll do some minor cleanups in the next few days, but other than that,
everything is good (right?).

OXullo Intersecans schrieb:
> Hithere!
> a little delay, sorry!
> 
> Il giorno 24/lug/07, alle ore 21:56, Ulrich von Zadow ha scritto:
> 
>> First, I fixed a compile error (I think it depends on the kernel version
>> - I have 2.6.21 here) in linux/videodev2.h. The fix is comitted on the
>> branch. Please check if that doesn't break on your computer.
> 
> I had to comment the two includes linux/types.h and linux/time.h
> (V4LCamera.cpp:36-37) due to a double inclusion error.
> Do you think that this would break yours? (please check against the
> latest commit)

It did break on my machine, but the bug was on my side. I had old kernel
headers from 2.6.11 installed. Still, good to know this breaks with old
kernels...


>> I just fixed this on the branch by adding a new pixel format. I have a
>> working USB camera here now!
> 
> that's perfect!
> I had a chance to test a Logitech QuickCam PRO 5000, which inits
> correctly (YUV422 (ok YUYV)) but displays a garbled colourspace.
> This cam is known to give a bunch of problem with v4l, therefore I don't
> consider this an appropriate test.
> What camera did you get working?

Um - a Logitech QuickCam PRO 5000. No problems whatsoever. But I added
an explicit pixel format YUYV422 which can be specified in the camera
node now, so you'll have to change the .avg file to redo the test.

>> The next thing is that the current camera node uses the width and height
>> attributes as the camera image width and height for V4L. However, these
>> are also used as the size of the image on the screen :-(. We should
>> really change that and use new attribute names for the camera resolution.
> 
> good.
> I added attributes capturewidth and captureheight to avg <video> node
> DTD and switched to these two instead of width/height
> (CameraNode.cpp:86-87).
> I wish that this won't break up nothing, conceptually. I tried to use
> the same notation format of the attribute identifier.

Perfect.

>> Also, while everything works here using V4L2_FIELD_INTERLACED, can you
>> check if V4L2_FIELD_ANY works as well? That should work for more
>> cameras, right?
> 
> Yes, this way the 'correct' format is selected contextually.
> FIELD_ANY works well with bt878

:-).

Cheers,

  Uli



More information about the libavg-devel mailing list