#10045 HIGH 1.5-sof: XO-1.5 Record audio/video are out of sync with each other

John Watlington wad at laptop.org
Sat May 15 07:31:07 EDT 2010

Given that the main memory is one eight to one quarter the size of
the storage medium, I'm surprised at the effort being invested in
recording straight to the storage medium.
Especially if that storage medium is arbitrarily slow!


On May 15, 2010, at 7:02 AM, Richard A. Smith wrote:

> On 05/13/2010 08:07 AM, Benjamin M. Schwartz wrote:
>> On 05/13/2010 03:26 AM, James Cameron wrote:
>>> We discussed this briefly in team meeting this morning ... Record is
>>> writing an uncompressed stream to SD, before then compressing it in the
>>> "Save" step once the video recording is stopped.  (I could be wrong).
>>> This means that no matter what the size of the buffer memory, if the
>>> data rate from the camera exceeds the rate at which we can write to SD,
>>> there will be skips once a recording is long enough to fill the buffer.
>> ...
>>> So we determine the data rate by choosing height, width, and frame rate
>>> from the camera.  We determine the maximum rate according to the choice
>>> of SD media.
>> If I understand correctly, Record does compress the video on the fly.
>> It's the audio that it writes uncompressed to disk for later compression
>> and muxing.  I don't know at what quality it performs audio recording, but
>> it might be as low as 32 KB/s uncompressed.
> I highly doubt that record is sending raw video to the SD device.  If it is then its broken and no wonder its skipping.  Raw 640x480 RGB at 30 frames a second is 27MiB/s.  Even if you use a YUV format with 16bits/pixel and 15 frames a second its still 9MiB/s which exceeds the sustained write rate of a class 6 card.  We ship class 2 (2MiB/s).
> If we can't do theora on the fly then we should be doing MJPEG or HuffYUV (if you wanted a lossless format).  Although HuffYUV is still going to be much faster than a Class 2 card.  Even MJPEG (roughly /10) is still pushing it.
> -- 
> Richard A. Smith  <richard at laptop.org>
> One Laptop per Child

More information about the Devel mailing list