Hi everybody,

I would like to find the general opinion on read() support in v4l2
drivers.  The v4l2 spec requires each read() to return data from a
different frame.  If the buffer is too small, either return -EINVAL, or
only the data that can fit into the buffer, then discard the rest of the
frame.  This means that simple stuff like cat fail, because of the
constant 4k buffer size (there is a vcat program for v4l2 that can
understand this though).

bttv-v4l2 broke this spec in that successive calls to read() returned
successive chunks of data from the same frame, so you could simply cat
/dev/video > whatever . This is very convenient, but breaks the spec. 
It also makes it very easy to get out of sync with the data, so you no
longer know where the frame starts (only within one open - future opens
start at the beginning of a frame again).

Which method should I implement in bttv2?  Stick with the standard, or
use the more convenient method?

Comments/opinions welcome!

-justin

PS - Our internet connection is fixed now, so you should be able to get
to the web server again.


-- 
         To unsubscribe: mail [EMAIL PROTECTED] with 
                       "unsubscribe" as the Subject.

Reply via email to