On Friday 04 December 2009 02:02:53 Melchior FRANZ wrote:
> * Laurent Pinchart -- Thursday 03 December 2009:
> > On Wednesday 02 December 2009 18:10:56 Melchior FRANZ wrote:
> > > I didn't find a reserved keysym for webcam snapshot buttons.
> >
> > What about XF86WebCam ?
> 
> I saw that one, but the definition says that it's for launching the "camera
>  app", not for taking a snapshot. Sure, I could use that locally, as my
>  keyboard doesn't have a camera launcher key. But this is probably not
>  generally usable.
> 
> XF86keysym.h:#define XF86XK_WebCam              0x1008FF8F   /* Launch web
>  camera app.    */

Good point. I'm not sure how formal the definition is though. And there's no 
formal definition for the webcam button usage either, it could be used to 
launch the web camera application :-)

> (And I had assumed that xmodmap can't assign keys from XF86keysym.h, but I
>  was wrong. It just has to be the raw value:  "keycode 187 = 0x1008FF8F".)
> 
> > The camera doesn't need to stream video to report button events. Holding
> > the video device node (/dev/videoX) open is enough. It should be quite
> > trivial to write an application that opens the device node and then
> > sleeps forever.
> 
> That would be trivial, indeed. But once open for supporting the snapshot
>  key, it can probably not be opened a second time for actually taking the
>  snapshot. I assume one would first have to close the device, then take the
>  shot, then grab the device again for the next shot. A bit messy. But I
>  don't care much, I just wondered.  :-)

The uvcvideo driver supports multiple opens. You can open the device in an 
application and sit there with the device opened without disturbing any other 
application. Of course, if you're trying to stream video in two separate 
applications at the same time, that's another story.

-- 
Regards,

Laurent Pinchart
_______________________________________________
Linux-uvc-devel mailing list
Linux-uvc-devel@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/linux-uvc-devel

Reply via email to