Re: Recording Endlessly w/o Memory Overflow?



Dave,

Thank you very much for your reply. It was difficult to "dig" up
this post after the massive thread attack by some person :(

As you have suggested, the AVI compression was the issue. I just
tried the uncompressed format, and disk logging keeps up with the
memory. GREAT!

After all, I am only interested in few minutes of recording at a
time, this greatly enhances the ability for me to capture everything
without loss of the image quality.

Peter

PS MPEG4 seems to be not supported by the MATLAB???

Dave Tarkowski wrote:

>
> Peter,
>
> Your assumptions on what is happening is basically correct.
> Incoming data
> is buffered in memory before being written to disk. As frames are
> written
> to disk, the associated memory is cleared allowing new frames to be
>
> acquired. Logging to disk is a slow process and if it is slower
> than the
> rate of acquisition, you will eventually run out of memory.
>
> The easiest way to deal with this is to change the format of the
> log file.
> The AVIFILE command that you use below uses the Indeo5 codec by
> default.
> Indeo5 is used by default because it is available on almost all
> computers
> running Windows. However, it is fairly slow for real time
> compression. I
> would suggest trying one of two other options, depending on your
> needs. The
> first would be to use uncompressed video. This will create very
> large files
> on disk, but will preserve the integrity of your data. If the
> uncompressed
> data doesn't work for you, try specifying "mp42" as the compression
> type for
> AVIFILE. This uses the Microsoft MPEG 4 version 2 codec. This
> codec is
> pretty commonly available, and much faster than the Indeo5 codec.
>
> To do this change the line:
>
> aviobj = avifile('logfile.avi');
>
> to
>
> aviobj = avifile('logfile.avi', 'Compression', 'none'); %
> Uncompressed
>
> or
>
> aviobj = avifile('logfile.avi', 'Compression', 'mp42'); % MPEG
> 4
> compression
>
> -Dave Tarkowski
.



Relevant Pages

  • Re: view menu
    ... When the file is opened into any graphical viewer or editor, the data is transferred from disk to memory so that the program can work with the data. ... We know that png uses data compression, so we can expect the uncompressed size to be much more. ... The image is 1080 pixels wide and 902 pixels high for a total of 1080x902 = 974160 pixels. ...
    (comp.graphics.apps.gimp)
  • Re: Reiser4. BEST FILESYSTEM EVER.
    ... I guess you have also not been hit by out of memory ... one with Reiser3 and the other with Reiser4. ... Seriously, disk storage is getting less expensive all the time, you can ... multiple files because of the compression in the file system. ...
    (Linux-Kernel)
  • memory pool, rfc
    ... The idea is to have a memory zone of N KB compressed in memory. ... I have fast compression algorithms now that can release under BSD licence that are faster than hd i/o, so it take less compress/decompress a memory zone than read/write it to disk. ...
    (freebsd-questions)
  • memory pool, rfc
    ... The idea is to have a memory zone of N KB compressed in memory. ... I have fast compression algorithms now that can release under BSD licence that are faster than hd i/o, so it take less compress/decompress a memory zone than read/write it to disk. ...
    (freebsd-hackers)
  • Proposed Assembler Commands
    ... ACM Automatically Clear Memory ... BKCRDR Backspace Card Reader ... BKSPD Backspace Disk ... EIAO Execute In Any Order ...
    (sci.electronics.design)