LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Grabbing snapshots from multiple webcam history

Solved!
Go to solution

Hi, I have three webcams (USB 3) connected to a Windows PC, LabVIEW 2018 with all the add-ons.I would like the ability to capture continuously from all 3 cameras 24/7, request a 'still' frame from their history (given a time t) on request from the user, and compress / store the oldest hour or so.

 

I've had a quick play with the vision tools - managed to capture video from multiple cameras using queues in while loops, but was unable to grab a frame in time.  

 

Any thoughts? 

 

Many thanks 

0 Kudos
Message 1 of 4
(2,673 Views)
Solution
Accepted by topic author grahamwebb

What sort of frame rate do you require? What size history buffer is required?

 

A simple implementation would be to grab and store individual frames as image files on disk, saved with a time stamp as part of the filename. When a user requests a frame at time t, the image file with the corresponding time in the filename is loaded from disk. You could do the same for video (say 1 minute or 10 minute captures), but it's a bit more of a pain to load and grab individual frames from a video.

 

Compressing the oldest hour of data probably won't save much in terms of disk space, as the images are already compressed (assuming JPEG). Periodically archiving the images/videos to another folder isn't a bad idea though.

 

You might also consider something else entirely to do the image/video acquisition and storage. I've used iSpy before which is an open source video surveillance software. You could set it up to monitor and capture from the three webcams, save either stills or video, then have a LabVIEW interface to do the history query based on the files stored on disk.




Certified LabVIEW Architect
Unless otherwise stated, all code snippets and examples provided
by me are "as is", and are free to use and modify without attribution.
Message 2 of 4
(2,643 Views)

I've had a quick play with the vision tools - managed to capture video from multiple cameras using queues in while loops, but was unable to grab a frame in time.  

 

Any thoughts? 

 

What tools are you planning to use? Using IMAQdx and LabVIEW, you can definitely implement your plans.

 

Have a look at the shipped example. In LabVIEW, goto menu Help » Find Examples..., then navigate to Hardware Input and Output » Vision Acquisition » NI-IMAQdx » High-Level » Grab.vi. In case your USB camera(s) are available in Windows' Device Manager, you can select them on the Front Panel of this VI as well. Running the VI will give you a stream from the selected camera:

LabVIEW_2018-12-13_10-01-18.png

 

Edit: This thread is a duplicate of Multiple USB webcam history, I moved my answer from there to here.


Ingo – LabVIEW 2013, 2014, 2015, 2016, 2017, 2018, NXG 2.0, 2.1, 3.0
CLADMSD
Message 3 of 4
(2,637 Views)

Hi Michael, 

 

Though not a LabVIEW solution, iSpy is working exactly as we wanted. Many Thanks.  

 

Graham

Message 4 of 4
(2,618 Views)