filter->diff_timestamp = -1;
gettimeofday (&filter->tv, NULL);
filter->starttime = 1000 * filter->tv.tv_sec;
- filter->previous_motion = false;
- filter->changed_datafile = false;
- filter->postallmotion = false;
- filter->usealpha = true;
- filter->firstdatafile = false;
- filter->firstgridx = true;
- filter->firstgridy = true;
- filter->changed_gridx = false;
- filter->changed_gridy = false;
- filter->firstframe = true;
- filter->changed_startime = false;
- filter->sent_init_error_msg = false;
- filter->sent_save_error_msg = false;
+ filter->previous_motion = FALSE;
+ filter->changed_datafile = FALSE;
+ filter->postallmotion = FALSE;
+ filter->usealpha = TRUE;
+ filter->firstdatafile = FALSE;
+ filter->firstgridx = TRUE;
+ filter->firstgridy = TRUE;
+ filter->changed_gridx = FALSE;
+ filter->changed_gridy = FALSE;
+ filter->firstframe = TRUE;
+ filter->changed_startime = FALSE;
+ filter->sent_init_error_msg = FALSE;
+ filter->sent_save_error_msg = FALSE;
filter->thickness = THICKNESS_DEF;
filter->datafileidx = 0;
case PROP_GRID_X:
filter->gridx = g_value_get_int (value);
if (filter->prevgridx != filter->gridx && !filter->firstframe) {
- filter->changed_gridx = true;
+ filter->changed_gridx = TRUE;
}
filter->prevgridx = filter->gridx;
break;
case PROP_GRID_Y:
filter->gridy = g_value_get_int (value);
if (filter->prevgridy != filter->gridy && !filter->firstframe) {
- filter->changed_gridy = true;
+ filter->changed_gridy = TRUE;
}
filter->prevgridy = filter->gridy;
break;
break;
case PROP_DATE:
if (!filter->firstframe) {
- filter->changed_startime = true;
+ filter->changed_startime = TRUE;
}
filter->starttime = g_value_get_long (value);
break;
motioncellscolor, motioncells_count, motioncellsidx, starttime,
datafile, changed_datafile, thickness, filter->id);
- if ((success == 1) && (filter->sent_init_error_msg == false)) {
+ if ((success == 1) && (filter->sent_init_error_msg == FALSE)) {
char *initfailedreason;
int initerrorcode;
GstStructure *s;
gst_element_post_message (GST_ELEMENT (filter), m);
filter->sent_init_error_msg = TRUE;
}
- if ((success == -1) && (filter->sent_save_error_msg == false)) {
+ if ((success == -1) && (filter->sent_save_error_msg == FALSE)) {
char *savefailedreason;
int saveerrorcode;
GstStructure *s;
detectedmotioncells = getMotionCellsIdx (filter->id);
if (detectedmotioncells) {
filter->consecutive_motion++;
- if ((filter->previous_motion == false)
+ if ((filter->previous_motion == FALSE)
&& (filter->consecutive_motion >= minimum_motion_frames)) {
GstStructure *s;
GstMessage *m;
- filter->previous_motion = true;
+ filter->previous_motion = TRUE;
filter->motion_begin_timestamp = GST_BUFFER_TIMESTAMP (buf);
s = gst_structure_new ("motion", "motion_cells_indices",
G_TYPE_STRING, detectedmotioncells, "motion_begin",
if (filter->previous_motion) {
GstStructure *s;
GstMessage *m;
- filter->previous_motion = false;
+ filter->previous_motion = FALSE;
s = gst_structure_new ("motion", "motion_finished", G_TYPE_UINT64,
filter->last_motion_timestamp, NULL);
m = gst_message_new_element (GST_OBJECT (filter), s);