From e26eaf90b16dd94586e3d8699796a3a0df259574 Mon Sep 17 00:00:00 2001 From: deva Date: Mon, 2 May 2005 14:06:55 +0000 Subject: Added unfreeze to decoder (called from camera). --- src/decoder.cc | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) (limited to 'src/decoder.cc') diff --git a/src/decoder.cc b/src/decoder.cc index a76105f..34c0185 100644 --- a/src/decoder.cc +++ b/src/decoder.cc @@ -25,6 +25,9 @@ */ /* * $Log$ + * Revision 1.26 2005/05/02 14:06:55 deva + * Added unfreeze to decoder (called from camera). + * * Revision 1.25 2005/05/02 10:52:46 deva * * Fixed bug invoking infinite loop, when snapshot is requested. @@ -173,6 +176,16 @@ void Decoder::freeze() b_freeze = true; } +/* + * Remove frozen frame. + */ +void Decoder::unfreeze() +{ + pthread_mutex_lock(&shot_mutex); + delete shot; + shot = NULL; + pthread_mutex_unlock(&shot_mutex); +} /* * Set shoot bit on current frame. @@ -186,9 +199,7 @@ void Decoder::shoot(unsigned char *rgb) // Wait for shot to be taken while(1) { pthread_mutex_lock(&shot_mutex); - fprintf(stderr, ":"); fflush(stderr); if(shot) { - fprintf(stderr, "."); fflush(stderr); getScreenshot(shot, rgb); delete shot; shot = NULL; -- cgit v1.2.3