09-25-2006 06:40 PM
09-27-2006 10:11 AM
Hi Aarthi,
You should be able to use the IMAQ Get Buffer VI to retrieve the image of your choice. I may not fully understand your question, so it might be helpful if you chould attach a small portion of your code so that I can take a look at it. Thanks.
Chris
Applications Engineer
National Instruments
09-27-2006 11:42 AM
09-27-2006 12:01 PM
Are you saying each image is 4 MB in size? If so, I doubt you can stream 30 fps to disk. That would be 120 MB/s to disk!! I think that exceeds the capability of most disk drives.
You won't be able to store all the images in memory at one time, unless you have 4 GB of memory available.
You might want to try compressing the images on the fly and keeping them in memory. The newer vision tools (v8 and above) include flatten image to string. If you select JPEG compression, it will reduce the image size considerably, and you can store the string in memory for saving later, or stream it to disk. I'm not sure if it would keep up with your acquisition, but if you create a large buffer you might do alright.
My advice: use a ring buffered acquisition with the most frames that you can fit in memory at one time. Figure out the best way to store the images while processing them fast enough that you won't overwrite the images. You probably should minimize the processing you are doing during the acquisition, since that will reduce the CPU availability for compressing and storing the images. Maybe just process one image a second and leave the rest of the CPU time for storage.
By the way, you can find out the last image acquired during a sequence. You just have to dig into the low level code for the sequence and duplicate it. Essential, a sequence is acquired the same way as a ring buffer, but you only go through the buffer once (one-shot).
Bruce
09-27-2006 12:31 PM
09-27-2006 12:36 PM
09-29-2006 12:35 PM
Aarthi,
What type of camera and framegrabber are you using? Also, do you have a more complete piece of code that I could look at? The parameters that are being passed into the VIs could have an effect on the synchronization problems you are seeing.
-Chris
Applications Engineer
National Instruments