mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-03-28 20:05:38 +00:00
basetextoverlay: use correct segment for text
video time uses the 'segment' and the text time should use the 'text_segment'. If different segments are used for video and text it would lead to out of sync video/subtitles.
This commit is contained in:
parent
c6915ea785
commit
ec7724c095
1 changed files with 4 additions and 4 deletions
|
@ -2194,11 +2194,11 @@ wait_for_text_buf:
|
|||
/* If timestamp and duration are valid */
|
||||
if (valid_text_time) {
|
||||
text_running_time =
|
||||
gst_segment_to_running_time (&overlay->segment, GST_FORMAT_TIME,
|
||||
text_start);
|
||||
gst_segment_to_running_time (&overlay->text_segment,
|
||||
GST_FORMAT_TIME, text_start);
|
||||
text_running_time_end =
|
||||
gst_segment_to_running_time (&overlay->segment, GST_FORMAT_TIME,
|
||||
text_end);
|
||||
gst_segment_to_running_time (&overlay->text_segment,
|
||||
GST_FORMAT_TIME, text_end);
|
||||
}
|
||||
|
||||
GST_LOG_OBJECT (overlay, "T: %" GST_TIME_FORMAT " - %" GST_TIME_FORMAT,
|
||||
|
|
Loading…
Reference in a new issue