qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] Webcams under KVM and Linux


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] Webcams under KVM and Linux
Date: Tue, 31 May 2011 09:01:57 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.17) Gecko/20110419 Red Hat/3.1.10-1.el6_0 Thunderbird/3.1.10

  Hi,

Takes a frame from ANY available V4L2 device (/dev/video0),
caches it, and sends it completely to the guest before requesting
any other frame.

I think you can double-buffer (i.e. let the host driver fill one
buffer while sending the other one to the guest).  Probably gives a
slightly higher frame rate, but maybe at cost of added latencies.

Indeed you can infinite-buffer it, but there is really no gain, the
added latency makes an effective lower frame rate (total number of
real frames seen by the guest in percentage)

Just two buffers, so capture and sending to the guest can be parallelized. More buffers don't really help and just increase latency.

Nice.  Patches are waiting for EHCI being merged I guess?

Patches are on RFC on June 2010 ML messages. There are some updates I
did to the emulation (internal conversion from YUV2 to MJPEG, gives
twice the framerate when the host webcam is YUV2 only) that I have
not sent to RFC yet.

Can you repost the latest version for review so we can get the bits merged?

There are also some things that can be enhanced (conversion of more
strange RAWs like OV511's, show the guest the controls of the real
webcam) easily but I won't do that until a legal problem about the
usage of my emulation code along with all the rest of QEMU by a
commercial vendor in violation of GPL is solved.

Thats fine, we can always add it later once the legal issues are sorted.

It works really well with USB 1.1 (up to 24fps with KVM, up to 10fps
with TCG), but your when EHCI is merged it will allow bigger
resolutions easily

Great.

The most curious and interesting thing is that, while the
specification says there can be webcams using bulk transfers (that's
what mine is doing) I've seen NONE in wild. All do ISO.

Using bulk certainly makes sense for a virtual device.

cheers,
  Gerd




reply via email to

[Prev in Thread] Current Thread [Next in Thread]