mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-19 16:21:17 +00:00
track-element: Handle the case where we have only one keyframe set when interpollating keyframes
This commit is contained in:
parent
7be28b29b2
commit
0fad60e754
1 changed files with 8 additions and 0 deletions
|
@ -312,6 +312,14 @@ interpolate_values_for_position (GstTimedValue * first_value,
|
|||
GstClockTime interval;
|
||||
gfloat value_at_pos;
|
||||
|
||||
g_assert (second_value || first_value);
|
||||
|
||||
if (first_value == NULL)
|
||||
return second_value->value;
|
||||
|
||||
if (second_value == NULL)
|
||||
return first_value->value;
|
||||
|
||||
diff = second_value->value - first_value->value;
|
||||
interval = second_value->timestamp - first_value->timestamp;
|
||||
|
||||
|
|
Loading…
Reference in a new issue