mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-20 04:56:24 +00:00
ges: Make sure not to set transition start to negative
gnlobject.start is a guint64, we can not set it to a negative value
This commit is contained in:
parent
7212307db5
commit
2fe6210383
1 changed files with 5 additions and 3 deletions
|
@ -163,7 +163,7 @@ static void
|
||||||
gstl_recalculate (GESSimpleTimelineLayer * self)
|
gstl_recalculate (GESSimpleTimelineLayer * self)
|
||||||
{
|
{
|
||||||
GList *tmp;
|
GList *tmp;
|
||||||
GstClockTime pos = 0;
|
gint64 pos = 0;
|
||||||
gint priority = 0;
|
gint priority = 0;
|
||||||
gint transition_priority = 0;
|
gint transition_priority = 0;
|
||||||
gint height;
|
gint height;
|
||||||
|
@ -210,9 +210,11 @@ gstl_recalculate (GESSimpleTimelineLayer * self)
|
||||||
} else if (GES_IS_TIMELINE_TRANSITION (obj)) {
|
} else if (GES_IS_TIMELINE_TRANSITION (obj)) {
|
||||||
|
|
||||||
pos -= dur;
|
pos -= dur;
|
||||||
|
if (pos < 0)
|
||||||
|
pos = 0;
|
||||||
|
|
||||||
GST_LOG ("%p obj: height: %d: trans_priority %d", obj, height,
|
GST_LOG ("%p obj: height: %d: trans_priority %d Position: %d, "
|
||||||
transition_priority);
|
"duration %d", obj, height, transition_priority, pos);
|
||||||
|
|
||||||
g_assert (transition_priority != -1);
|
g_assert (transition_priority != -1);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue