From a1b55f03e2fe40d4e14278745eae473b73fe81fe Mon Sep 17 00:00:00 2001 From: Eugeniy Mikhailov Date: Tue, 18 Sep 2012 09:20:09 -0400 Subject: separate function to grab images --- grabimage.m | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 grabimage.m diff --git a/grabimage.m b/grabimage.m new file mode 100644 index 0000000..c57f41d --- /dev/null +++ b/grabimage.m @@ -0,0 +1,9 @@ +function img=grabimage(shutter_time, Naverages) +% This funcion calls the external program which takes an image from camera +% with apropriate settings. +cmnd_string = horzcat('grabNimages_1394cam.exe', ' -s ',num2str(shutter_time),' -n ',num2str(Naverages)); +[status,result] = system(cmnd_string); +% by default our grabber save png image to this file name +image_name = 'test.png'; +img=imread(image_name); + -- cgit v1.2.3