From 6461f2e549876cb54456925f47094bb53e2c8672 Mon Sep 17 00:00:00 2001 From: "Suren A. Chilingaryan" Date: Thu, 2 Feb 2012 17:30:04 +0100 Subject: Add preliminary UFO camera support back again --- test/grab.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'test') diff --git a/test/grab.c b/test/grab.c index b7c24dd..54e6955 100644 --- a/test/grab.c +++ b/test/grab.c @@ -75,6 +75,9 @@ int main(int argc, char *argv[]) while ((error == UCA_NO_ERROR) && (counter < 20)) { error = uca_cam_grab(cam, (char *) buffer, NULL); + if (error != UCA_NO_ERROR) + break; + snprintf(filename, FILENAME_MAX, "frame-%08i.raw", counter++); FILE *fp = fopen(filename, "wb"); fwrite(buffer, width*height, pixel_size, fp); -- cgit v1.2.3