From d62dfce98fda79ef6cd10d4089141c81fe994223 Mon Sep 17 00:00:00 2001 From: John Stebbins Date: Fri, 2 Aug 2019 11:41:13 -0700 Subject: add subtitle track name read/write Works similar to audio track names. If source has a subtitle track name, hb_subtitle_t.name is set. To set output subtitle track name, set hb_subtitle_config_t.name. Source track names are available in title returned by hb_title_to_dict and hb_title_to_json in SubtitleList[].Name In job dict it is also SubtitleList[].Name hb_preset_job_init and hb_preset_job_init_json initialize output tracks with the source track name. Also adds subtitle name support to LinGui --- gtk/src/ghb3.ui | 470 ++++++++++++++++++++++++++++++-------------------------- 1 file changed, 253 insertions(+), 217 deletions(-) (limited to 'gtk/src/ghb3.ui') diff --git a/gtk/src/ghb3.ui b/gtk/src/ghb3.ui index eccd56efc..1a7eea08a 100644 --- a/gtk/src/ghb3.ui +++ b/gtk/src/ghb3.ui @@ -8732,6 +8732,7 @@ Setting this to 0 means there is no maximum height. + vertical True False 6 @@ -8796,264 +8797,298 @@ Setting this to 0 means there is no maximum height. + + 0 + + + + + 2 + True + False + 5 + center + + + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Source Track + + + 0 + 0 + 1 + 1 + + + + + GTK_ALIGN_CENTER + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + List of subtitle tracks available from your source. + + + + 1 + 0 + 1 + 1 + + + + + True + False + Track Name: + True + center + + + 0 + 1 + 1 + 1 + + + + + True + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Set the subtitle track name. + +Players may use this in the subtitle selection list. + 80 + 40 + True + True + + + + 1 + 1 + 1 + 1 + + + 1 - - horizontal + True + 2 False - 6 + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + 4 - + True - 2 False GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - 4 - - - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Language - - - 0 - 1 - 1 - 1 - - - - - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Character Code - - - 0 - 2 - 1 - 1 - - - - - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - File: - end - - - 2 - 0 - 1 - 1 - - - - - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Offset (ms) - - - 0 - 4 - 1 - 1 - - - - - GTK_ALIGN_CENTER - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Set the language of this subtitle. + Language + + + 0 + 1 + 1 + 1 + + + + + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Character Code + + + 0 + 2 + 1 + 1 + + + + + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + File: + end + + + 2 + 0 + 1 + 1 + + + + + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Offset (ms) + + + 0 + 4 + 1 + 1 + + + + + GTK_ALIGN_CENTER + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Set the language of this subtitle. This value will be used by players in subtitle menus. - - - - 1 - 1 - 1 - 1 - - - - - GTK_ALIGN_FILL - 150 - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Set the character code used by the SRT file you are importing. + + + + 1 + 1 + 1 + 1 + + + + + GTK_ALIGN_FILL + 150 + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Set the character code used by the SRT file you are importing. SRTs come in all flavours of character sets. We translate the character set to UTF-8. The source's character code is needed in order to perform this translation. - - True - - - True - - - - - 1 - 2 - 1 - 1 - - - - - True - True - Select the SRT file to import. - False - True - Import File - - - - 2 - 1 - 2 - 1 - - - - - GTK_ALIGN_FILL - False - 8 - True + + True + + True - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Adjust the offset in milliseconds between video and SRT timestamps - adjustment31 - - - 1 - 4 - 1 - 1 - - 0 + 1 + 2 + 1 + 1 - - vertical + True - False - - - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Track - - - 0 - - - - - GTK_ALIGN_CENTER - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - List of subtitle tracks available from your source. - - - - 1 - - + True + Select the SRT file to import. + False + True + Import File + - 1 + 2 + 1 + 2 + 1 - - vertical + + GTK_ALIGN_FILL + False + 8 True - False - - - Forced Subtitles Only - True - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Use only subtitles that have been flagged + True + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Adjust the offset in milliseconds between video and SRT timestamps + adjustment31 + + + + 1 + 4 + 1 + 1 + + + + + 2 + + + + + vertical + True + False + 12 + + + Forced Subtitles Only + True + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Use only subtitles that have been flagged as forced in the source subtitle track "Forced" subtitles are usually used to show subtitles during scenes where someone is speaking a foreign language. - start - True - - - - 0 - - - - - Burn into video - True - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Render the subtitle over the video. + start + True + + + + 0 + + + + + Burn into video + True + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Render the subtitle over the video. The subtitle will be part of the video and can not be disabled. - start - True - - - - 1 - - - - - Set Default Track - True - True - False - GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK - Set the default output subtitle track. + start + True + + + + 1 + + + + + Set Default Track + True + True + False + GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK + Set the default output subtitle track. Most players will automatically display this subtitle track whenever the video is played. This is useful for creating a "forced" track in your output. - start - True - - - - 2 - - + start + True + 2 @@ -9061,7 +9096,7 @@ in your output. - 2 + 3 @@ -9170,7 +9205,8 @@ in your output. Set the audio track name. Players may use this in the audio selection list. - 40 + 80 + 40 True True True -- cgit v1.2.3