On 11/3/06, Pablo d'Angelo <[EMAIL PROTECTED]> wrote:
Denis McLaughlin wrote:
>  - While the USB 2 bus can support 8 streaming cams, there seems to be a
> fair bit of jitter in capture time.  The capture utility I wrote
> time-stamps each frame as it receives it, but while the frames are
> generally uniformly spaced 0.066s, there are occasional dropouts and
> periods where frames are snapped very quickly one after another.  I
> haven't done enough testing to know whether this jitter gets worse with
> more web cams or not.

That doesn't sound very good for my application, since I need synchronised
images (audio is not so important for me). Is the timestamp you recorded an
accurate indicator for the capture time, or is it independent from that?

  The timestamp is just gettimeofday() called from the program doing the capture, so it's an accurate upper bound on the frame capture time (ie. the frame can't have been captured any later than the time stamp).although it's unclear when in the preceding interval the picture actually came from.  I don't want to overstate the problem: by and large, the cameras do hit 15 fps quite accurately, it's just that there is some jitter.

  To back this up with a little data, you can see the capture times for a single camera here: http://denism.homeip.net/stuff/capture-times, the differences between consecutive frames here: http://denism.homeip.net/stuff/capture-differences, and I've generated a histogram of those differences here: http://denism.homeip.net/stuff/interframe-histogram.png against a logarithmic Y axis.  The histogram shows that the vast majority of the inter-frame differences are in the 0.06-ish area, but there are a number faster and slower than that.

  Whether or not this jitter is big enough to cause a problem depends on how synchronized you need frames from the cameras to be: the jitter I show above is quite tolerable for my purposes.


>  - Likely as a consequence of the time jitter in the USB bus (or maybe a
> problem with the cams?  or maybe my capture program?), I'm having a lot
> of trouble trying to synchronize the video streams from the fusions with
> the audio I recorded.  I'm still working on a solution to this one... :(

If the timestamp itself is a reliable measure for the jitter, it might be
possible to leave out or duplicate some frames in post processing.

  Yeah, I have a script that massages the frames, selecting the right ones and duping to fill in gaps as needed.  I actually had a breakthrough last night, when I realized my audio/visual synch wasn't caused by the video frames being non-uniform, but rather that the audio I recorded from the USB mics isn't correct.  When I matched the video up against the audio from a DV video camera filming the same scene, everything looked fine (wrt synch).  Yay!  So my audio-visual synch problem was actually caused by a problem with my USB audio recording (though there is still some variability in frame capture times, as shown above).

Denis
_______________________________________________
Linux-uvc-devel mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/linux-uvc-devel

Reply via email to