mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-28 20:05:38 +00:00
inputselector: handle more formats
Use the segment format instead of a hardcoded _TIME.
This commit is contained in:
parent
115c34badd
commit
f6178ee53e
1 changed files with 3 additions and 3 deletions
|
@ -295,11 +295,11 @@ gst_selector_pad_get_running_time (GstSelectorPad * pad)
|
|||
|
||||
GST_OBJECT_LOCK (pad);
|
||||
if (pad->active) {
|
||||
gint64 position = pad->segment.position;
|
||||
guint64 position = pad->segment.position;
|
||||
GstFormat format = pad->segment.format;
|
||||
|
||||
if (position >= 0)
|
||||
ret = gst_segment_to_running_time (&pad->segment, GST_FORMAT_TIME,
|
||||
position);
|
||||
ret = gst_segment_to_running_time (&pad->segment, format, position);
|
||||
}
|
||||
GST_OBJECT_UNLOCK (pad);
|
||||
|
||||
|
|
Loading…
Reference in a new issue