12-09-2020 04:21 AM
Hello,
I am trying to save a video with a delay before and after a trig.
I am new to labview so im not sure the function I used are the good one.
For testing I use the webcam on my laptop and the example VI "Grab and select video mode".
First I modified the vi to record on a trig 5 sec of video, it worked.
But now I have to constantly store the last 5 sec of the video and save them when the trig occure, for that I used the queue elements and queue 150 frame (my record are in 30 frame / sec).
Then every time there is 151 frame in the queue, I send one to the record IMAQ AVI2 Write Frame, but it don't work.
Anybody has idea what I did wrong ? I appreciate your thoughts and help.
12-09-2020 04:44 AM
All the images that end up in the queue are the same image. They have the same name, so they will overwrite each other.
You should make an array of images with all different names, and use that as a buffer. You could still use a queue, but a lossy queue is probably more appropriate.