[Elphel-support] 100 fps questions

Andrey Filippov andrey at elphel.com
Thu Feb 18 22:41:58 PST 2010


Hello Brian,

> 1) Can the 353 capture 640x480 video at 100+ fps even when recording in  "jpeg" mode - i.e. writing individual JPG's for each frame?  If so, which  would be better (i.e faster & more reliable) to write to - CF or HDD?

I would still recommend using MOV file, each frame includes the same
Exif headers as individual JPEGs. When recording many files, there is
a large CPU overhead when directories grow big.

> 2) Can the 353 be configured to capture non-standard dimension video - say,  64x960 - and still record at 100+ fps?

Frame size should be multiple of 16x16 pixels, so 64x960 is OK. Just
tried it with the camera - frame timestamps are 1.517ms apart. I
checked that image sequence in the 19MB RAM buffer, did not test it
yet on the actual HDD, there may be some problems at this 660fps - in
that case it should be possible to reduce overhead even more - i.e
record multipart JPEG file from the camera image server
(127.0.0.1:8081/mimg) directly to a single open file.


> Since the finish line is "vertical",  it'd be nice to be able to trade space in the horizontal dimension in  exchange for the vertical.

Yes, sure. And camera should be in "portrait mode" (lines go vertical)
- fps will be higher as sensors have much larger "horizontal margins"
than the vertical ones.

> 3) There's an excellent 100 fps finish line video called "100 FPS with  timestamps watermarked" at  http://wiki.elphel.com/index.php?title=Images_and_videos_examples.  My broad  question is, how can I do that?

It wasn't me who made that video, Alexandre Poltorak will be able to
answer you better on that

 I know how to add a timestamp (from the > EXIF data) watermark to an
individual JPG using PHP.  To get the effect in  that video, would it
be better/easier to:
>
> a) Record individual JPG's, watermark them all with a script, then merge
> them together into a movie, or

Image acquisition, compression and adding timestamps - all that is
handled by the FPGA. All the rest is done by software (and camera has
just 200MHz CPU). Recording individual JPEGs most certainly would
limit the frame rate.

> b) Record an MJPEG in a MOV/OGG, and somehow parse through the frames (using  some PHP extension, perhaps?) adding the watermark, or

Yes, that is the most practical solution. I would recommend MOV -
least CPU overhead. Each frame in the file is a compete JPEG (with
Exif), so you can parse the file just by detecting tags, you do not
even need to correctly parse the MOV container. Just find the first
frame (all the directory/file info is recorded in the beginning of the
file) looking for signatures,the rest of the file is just a sequence
of merged JPEG frames.

> c) Is it possible to add the watermark to each frame as it's being recorded - i.e. (presumably) modifying camogm?

We did try such watermarking (in the FPGA - camogm handles complete
JPEG frames, not the pixels), but it is not that flexible as you can
do in post-processing reading timestamp from each frame. And I would
definitely avoid extra processing in the camera - only the FPGA there
is fast. So you may only need to modify camogm the other way - make
merge certain number of frames (i.e. 10) together, providing a single
Exif header for them (you'll still be able to preserve each individual
frame timestamp) to reduce the CPU overhead during recording.
Camera FPGA provides compressed images in the 19MB RAM buffer without
any CPU work, each frame has additional 32 byte info block (including
timestamp), the highest possible FPS can be achieved if this buffer is
just read (through the camera driver) and copied to the large file on
the HDD.

Andrey




More information about the Support-list mailing list