mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
resindvd: Ensure we send a title tag in the first play section.
This commit is contained in:
parent
f2f79cd410
commit
c0854113a1
1 changed files with 40 additions and 35 deletions
|
@ -767,7 +767,14 @@ update_title_info (resinDvdSrc * src)
|
|||
}
|
||||
|
||||
if (dvdnav_current_title_info (src->dvdnav, &title_n,
|
||||
&part_n) == DVDNAV_STATUS_OK) {
|
||||
&part_n) != DVDNAV_STATUS_OK) {
|
||||
if (!src->in_menu)
|
||||
return; /* Can't update now */
|
||||
/* Must be in the first play sequence */
|
||||
title_n = -1;
|
||||
part_n = 0;
|
||||
}
|
||||
|
||||
if (title_n != src->title_n || part_n != src->part_n ||
|
||||
src->n_angles != n_angles || src->cur_angle != cur_agl) {
|
||||
gchar *title_str = NULL;
|
||||
|
@ -780,7 +787,7 @@ update_title_info (resinDvdSrc * src)
|
|||
if (title_n == 0) {
|
||||
/* In a menu */
|
||||
title_str = g_strdup ("DVD Menu");
|
||||
} else {
|
||||
} else if (title_n > 0) {
|
||||
/* In a title */
|
||||
if (n_angles > 1) {
|
||||
title_str = g_strdup_printf ("Title %i, Chapter %i, Angle %i of %i",
|
||||
|
@ -809,7 +816,6 @@ update_title_info (resinDvdSrc * src)
|
|||
gst_element_found_tags (GST_ELEMENT_CAST (src), tags);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static GstFlowReturn
|
||||
|
@ -911,7 +917,6 @@ rsn_dvdsrc_step (resinDvdSrc * src, gboolean have_dvd_lock)
|
|||
src->next_is_nav_block = FALSE;
|
||||
src->next_nav_ts = GST_CLOCK_TIME_NONE;
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
case DVDNAV_STOP:
|
||||
|
|
Loading…
Reference in a new issue