Hi Javier, My apologies for the late reply. On Mon, Jan 21, 2013 at 12:20:23PM +0100, javier Martin wrote: > Hi, > ov7670 and ov7675 sensors have the possibility of querying the average > value of the Y/Cb components of the image reading a register. This > could be useful for applications such as calise [1]. This program > grabs frames from a video camera, calculates the average brightness > and then adjusts screen's backlight accordingly. > > If the user could query the value of this register t in cameras that > support it we could save a lot of processing effort. > > The first idea that came into my mind was to define a new v4l2-ctrl > for this but I'm not sure if it is a common feature in other sensors. > Is it worth it to define a new v4l2-ctrl for this or should I use a > private ctrl instead? Is this register something you can just read back from the sensor, or is it associated to a particular frame? In general the information sounds like such that it should be part of the frame metadata, but I don't think the driver should read the value back from the sensor just to provide the metadata to the user space. I could imagine that most of the time the user space wouldn't be even interested in that at all, but only in very specific situations. (Related to the recent frame metadata discussion, not to your proposal.) So I'm also leaning towards having a control for the purpose. I haven't seen a sensor which would implement the same (anyone else?) so I'd probably start with a private control. Cc Hans and Laurent. -- Kind regards, Sakari Ailus e-mail: sakari.ailus@xxxxxx XMPP: sailus@xxxxxxxxxxxxxx -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html