Changed preventive zones to preclusive.
git-svn-id: http://svn.zoneminder.com/svn/zm/trunk@488 e3e1d417-86f3-4887-817a-d78f3d33393f
This commit is contained in:
parent
297a72dae9
commit
3232656595
|
@ -4,7 +4,7 @@
|
||||||
alter table Monitors change column Colours Palette tinyint(3) unsigned NOT NULL default '1';
|
alter table Monitors change column Colours Palette tinyint(3) unsigned NOT NULL default '1';
|
||||||
update Monitors set Palette = 1 where Palette = 8;
|
update Monitors set Palette = 1 where Palette = 8;
|
||||||
update Monitors set Palette = 4 where Palette = 24;
|
update Monitors set Palette = 4 where Palette = 24;
|
||||||
alter table Zones modify column Type enum('Active','Inclusive','Exclusive','Inactive','Preventive') not null default 'Active';
|
alter table Zones modify column Type enum('Active','Inclusive','Exclusive','Preclusive','Inactive') not null default 'Active';
|
||||||
-- These are optional, it just seemed a good time...
|
-- These are optional, it just seemed a good time...
|
||||||
optimize table Frames;
|
optimize table Frames;
|
||||||
optimize table Events;
|
optimize table Events;
|
||||||
|
|
|
@ -786,15 +786,15 @@ unsigned int Monitor::Compare( const Image &image )
|
||||||
delta_image->Fill( RGB_BLACK, &(zone->Limits()) );
|
delta_image->Fill( RGB_BLACK, &(zone->Limits()) );
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check preventive zones first
|
// Check preclusive zones first
|
||||||
for ( int n_zone = 0; n_zone < n_zones; n_zone++ )
|
for ( int n_zone = 0; n_zone < n_zones; n_zone++ )
|
||||||
{
|
{
|
||||||
Zone *zone = zones[n_zone];
|
Zone *zone = zones[n_zone];
|
||||||
if ( !zone->IsPreventive() )
|
if ( !zone->IsPreclusive() )
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
Debug( 3, ( "Checking preventive zone %s", zone->Label() ));
|
Debug( 3, ( "Checking preclusive zone %s", zone->Label() ));
|
||||||
if ( zone->CheckAlarms( delta_image ) )
|
if ( zone->CheckAlarms( delta_image ) )
|
||||||
{
|
{
|
||||||
alarm = true;
|
alarm = true;
|
||||||
|
|
|
@ -478,8 +478,8 @@ bool Zone::DumpSettings( char *output, bool verbose )
|
||||||
type==ACTIVE?"Active":(
|
type==ACTIVE?"Active":(
|
||||||
type==INCLUSIVE?"Inclusive":(
|
type==INCLUSIVE?"Inclusive":(
|
||||||
type==EXCLUSIVE?"Exclusive":(
|
type==EXCLUSIVE?"Exclusive":(
|
||||||
type==INACTIVE?"Inactive":(
|
type==PRECLUSIVE?"Preclusive":(
|
||||||
type==PREVENTIVE?"Preventive":"Unknown"
|
type==INACTIVE?"Inactive":"Unknown"
|
||||||
)))));
|
)))));
|
||||||
sprintf( output+strlen(output), " Limits : %d,%d - %d,%d\n", limits.LoX(), limits.LoY(), limits.HiX(), limits.HiY() );
|
sprintf( output+strlen(output), " Limits : %d,%d - %d,%d\n", limits.LoX(), limits.LoY(), limits.HiX(), limits.HiY() );
|
||||||
sprintf( output+strlen(output), " Alarm RGB : %06x\n", alarm_rgb );
|
sprintf( output+strlen(output), " Alarm RGB : %06x\n", alarm_rgb );
|
||||||
|
|
|
@ -35,7 +35,7 @@ class Monitor;
|
||||||
class Zone
|
class Zone
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
typedef enum { ACTIVE=1, INCLUSIVE, EXCLUSIVE, INACTIVE, PREVENTIVE } ZoneType;
|
typedef enum { ACTIVE=1, INCLUSIVE, EXCLUSIVE, PRECLUSIVE, INACTIVE } ZoneType;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
// Inputs
|
// Inputs
|
||||||
|
@ -97,8 +97,8 @@ public:
|
||||||
inline bool IsActive() const { return( type == ACTIVE ); }
|
inline bool IsActive() const { return( type == ACTIVE ); }
|
||||||
inline bool IsInclusive() const { return( type == INCLUSIVE ); }
|
inline bool IsInclusive() const { return( type == INCLUSIVE ); }
|
||||||
inline bool IsExclusive() const { return( type == EXCLUSIVE ); }
|
inline bool IsExclusive() const { return( type == EXCLUSIVE ); }
|
||||||
|
inline bool IsPreclusive() const { return( type == PRECLUSIVE ); }
|
||||||
inline bool IsInactive() const { return( type == INACTIVE ); }
|
inline bool IsInactive() const { return( type == INACTIVE ); }
|
||||||
inline bool IsPreventive() const { return( type == PREVENTIVE ); }
|
|
||||||
inline Image &AlarmImage() const { return( *image ); }
|
inline Image &AlarmImage() const { return( *image ); }
|
||||||
inline const Box &Limits() const { return( limits ); }
|
inline const Box &Limits() const { return( limits ); }
|
||||||
inline bool Alarmed() const { return( alarmed ); }
|
inline bool Alarmed() const { return( alarmed ); }
|
||||||
|
|
|
@ -2248,7 +2248,7 @@ function applyZoneType(theForm)
|
||||||
theForm.new_max_blobs.disabled = true;
|
theForm.new_max_blobs.disabled = true;
|
||||||
theForm.new_max_blobs.value = "";
|
theForm.new_max_blobs.value = "";
|
||||||
}
|
}
|
||||||
else if ( theForm.new_type.value == 'Preventive' )
|
else if ( theForm.new_type.value == 'Preclusive' )
|
||||||
{
|
{
|
||||||
theForm.new_alarm_rgb_r.disabled = true;
|
theForm.new_alarm_rgb_r.disabled = true;
|
||||||
theForm.new_alarm_rgb_r.value = "";
|
theForm.new_alarm_rgb_r.value = "";
|
||||||
|
|
Loading…
Reference in New Issue