From 7031f10aee0714f02ea3df2203730eb02584ccfc Mon Sep 17 00:00:00 2001 From: Matthias Vogelgesang Date: Tue, 22 Mar 2011 08:48:42 +0100 Subject: Use latest picture number when requesting new ones --- src/grabbers/me4.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/grabbers') diff --git a/src/grabbers/me4.c b/src/grabbers/me4.c index aea67f0..4c6420e 100644 --- a/src/grabbers/me4.c +++ b/src/grabbers/me4.c @@ -138,11 +138,11 @@ uint32_t uca_me4_stop_acquire(struct uca_grabber *grabber) uint32_t uca_me4_grab(struct uca_grabber *grabber, void **buffer, uint32_t *frame_number) { - int32_t last_frame; + static int32_t last_frame = 0; if (grabber->asynchronous) last_frame = Fg_getLastPicNumberEx(GET_FG(grabber), PORT_A, GET_MEM(grabber)); else - last_frame = Fg_getLastPicNumberBlockingEx(GET_FG(grabber), 1, PORT_A, 10, GET_MEM(grabber)); + last_frame = Fg_getLastPicNumberBlockingEx(GET_FG(grabber), last_frame+1, PORT_A, 10, GET_MEM(grabber)); if (last_frame <= 0) return UCA_ERR_PROP_GENERAL; -- cgit v1.2.3