diff --git a/ges/nle/nlecomposition.c b/ges/nle/nlecomposition.c index 77416d3e13..ca453ae687 100644 --- a/ges/nle/nlecomposition.c +++ b/ges/nle/nlecomposition.c @@ -1696,7 +1696,7 @@ refine_start_stop_in_region_above_priority (NleComposition * composition, GST_LOG_OBJECT (object, "START %" GST_TIME_FORMAT "--%" GST_TIME_FORMAT, GST_TIME_ARGS (object->start), GST_TIME_ARGS (object->stop)); - if ((object->priority >= priority) || (!object->active)) + if ((object->priority >= priority) || (!NLE_OBJECT_ACTIVE (object))) continue; if (object->start <= timestamp) @@ -1721,7 +1721,7 @@ refine_start_stop_in_region_above_priority (NleComposition * composition, GST_LOG_OBJECT (object, "STOP %" GST_TIME_FORMAT "--%" GST_TIME_FORMAT, GST_TIME_ARGS (object->start), GST_TIME_ARGS (object->stop)); - if ((object->priority >= priority) || (!object->active)) + if ((object->priority >= priority) || (!NLE_OBJECT_ACTIVE (object))) continue; if (object->stop >= timestamp) @@ -1880,7 +1880,7 @@ get_stack_list (NleComposition * comp, GstClockTime timestamp, if (object->stop >= timestamp) { if ((object->start < timestamp) && (object->priority >= priority) && - ((!activeonly) || (object->active))) { + ((!activeonly) || (NLE_OBJECT_ACTIVE (object)))) { GST_LOG_OBJECT (comp, "adding %s: sorted to the stack", GST_OBJECT_NAME (object)); stack = g_list_insert_sorted (stack, object, @@ -1907,7 +1907,7 @@ get_stack_list (NleComposition * comp, GstClockTime timestamp, if (object->start <= timestamp) { if ((object->stop > timestamp) && (object->priority >= priority) && - ((!activeonly) || (object->active))) { + ((!activeonly) || (NLE_OBJECT_ACTIVE (object)))) { GST_LOG_OBJECT (comp, "adding %s: sorted to the stack", GST_OBJECT_NAME (object)); stack = g_list_insert_sorted (stack, object, diff --git a/ges/nle/nleobject.h b/ges/nle/nleobject.h index a8fc78713f..1e0272e4ae 100644 --- a/ges/nle/nleobject.h +++ b/ges/nle/nleobject.h @@ -79,6 +79,7 @@ typedef enum #define NLE_OBJECT_DURATION(obj) (NLE_OBJECT_CAST (obj)->duration) #define NLE_OBJECT_INPOINT(obj) (NLE_OBJECT_CAST (obj)->inpoint) #define NLE_OBJECT_PRIORITY(obj) (NLE_OBJECT_CAST (obj)->priority) +#define NLE_OBJECT_ACTIVE(obj) (NLE_OBJECT_DURATION(obj) > 0 && NLE_OBJECT_CAST (obj)->active) #define NLE_OBJECT_IS_COMMITING(obj) (NLE_OBJECT_CAST (obj)->commiting)