Raspistill and OF

I’m working on a Raspberry Pi to create a camera trap that takes a photo and immediately displays it onscreen until the next time a sensor is tripped (while also animating thumbnails of the last few images taken). I’m also having trouble getting the camera add-on to work.

Is there a way to run Raspistill from within OF? As I was writing this draft, I came across the C++ function “system()” Is it considered OK practice to use it? Or, if I get the camera add-on working, can I grab a still as the video is running and would that be the better practice?


Found the answer to my question. On the forum, I found this:


…and also came across a way to pass in a variable:

I haven’t tried passing in a variable yet but system() and raspistill worked, f.g.:
system(“raspistill -t 100 -q 50 -o captures/pic-1.jpg -e jpg -w 640 -h 480 -n -ss 8000”);