Add support for event with multiple causes
This commit is contained in:
parent
217aafee5a
commit
5d5d9c5009
|
@ -210,6 +210,16 @@ void Event::createNotes( std::string ¬es )
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Event::AddCause( const std::string new_cause )
|
||||||
|
{
|
||||||
|
if ( cause.find( new_cause ) == std::string::npos )
|
||||||
|
{
|
||||||
|
if ( cause.length() )
|
||||||
|
cause += ", ";
|
||||||
|
cause += new_cause;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
int Event::sd = -1;
|
int Event::sd = -1;
|
||||||
|
|
||||||
bool Event::OpenFrameSocket( int monitor_id )
|
bool Event::OpenFrameSocket( int monitor_id )
|
||||||
|
|
|
@ -132,6 +132,7 @@ public:
|
||||||
|
|
||||||
void AddFrames( int n_frames, Image **images, struct timeval **timestamps );
|
void AddFrames( int n_frames, Image **images, struct timeval **timestamps );
|
||||||
void AddFrame( Image *image, struct timeval timestamp, int score=0, Image *alarm_frame=NULL );
|
void AddFrame( Image *image, struct timeval timestamp, int score=0, Image *alarm_frame=NULL );
|
||||||
|
void AddCause( const std::string new_cause );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void AddFramesInternal( int n_frames, int start_frame, Image **images, struct timeval **timestamps );
|
void AddFramesInternal( int n_frames, int start_frame, Image **images, struct timeval **timestamps );
|
||||||
|
|
Loading…
Reference in New Issue