From a7a471d58da9e4c6cdd904d75a9a3a5ca1b0283c Mon Sep 17 00:00:00 2001 From: stan Date: Tue, 23 Sep 2003 09:50:25 +0000 Subject: [PATCH] Updated to handle very low frame rates. git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@635 e3e1d417-86f3-4887-817a-d78f3d33393f --- scripts/zmwatch.pl.z | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scripts/zmwatch.pl.z b/scripts/zmwatch.pl.z index 10aee9146..52e46fd6b 100755 --- a/scripts/zmwatch.pl.z +++ b/scripts/zmwatch.pl.z @@ -135,9 +135,10 @@ while( 1 ) next; } + my $max_image_delay = $monitor->{MaxFPS}>0?(10/$monitor->{MaxFPS}):ZM_WATCH_MAX_DELAY; my $image_delay = $now-$image_time; - print( "Monitor $monitor->{Id} last captured $image_delay seconds ago\n" ) if ( VERBOSE ); - if ( $image_delay <= ZM_WATCH_MAX_DELAY ) + print( "Monitor $monitor->{Id} last captured $image_delay seconds ago, max is $max_image_delay\n" ) if ( VERBOSE ); + if ( $image_delay <= $max_image_delay ) { # Yes, so continue next;