mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-18 15:51:11 +00:00
dvbsuboverlay: ensure minimum page time out of 1 second
... to compensate for some bogus subtitle with a 0 timeout, which would result in only being shown for a very unreadable amount of time. See https://bugzilla.gnome.org/show_bug.cgi?id=666674
This commit is contained in:
parent
1754e12623
commit
4374a90553
1 changed files with 7 additions and 0 deletions
|
@ -764,6 +764,13 @@ new_dvb_subtitles_cb (DvbSub * dvb_sub, DVBSubtitles * subs, gpointer user_data)
|
|||
subs->page_time_out, subs->num_rects, subs->pts,
|
||||
GST_TIME_ARGS (subs->pts));
|
||||
|
||||
/* spec says page_time_out is not to be taken very accurately anyway,
|
||||
* and 0 does not make useful sense anyway */
|
||||
if (!subs->page_time_out) {
|
||||
GST_WARNING_OBJECT (overlay, "overriding page_time_out 0");
|
||||
subs->page_time_out = 1;
|
||||
}
|
||||
|
||||
/* clip and convert to running time */
|
||||
start = subs->pts;
|
||||
stop = subs->pts + subs->page_time_out;
|
||||
|
|
Loading…
Reference in a new issue