improvements CR-Beta stream selector

improvements CR-Beta stream selector (json processing)
expanded season ignore for all seasons #498
This commit is contained in:
hama3254 2022-06-24 16:11:21 +02:00
parent 7b0085d6b9
commit f52cdce053
4 changed files with 249 additions and 187 deletions

Binary file not shown.

View File

@ -65,7 +65,8 @@ Public Class Main
Public LogBrowserData As Boolean = False
Public Thumbnail As String = Nothing
Public MergeSubs As Boolean = False
Public IgnoreS1 As Boolean = False
'Public IgnoreS1 As Boolean = False
Public IgnoreSeason As Integer = 0
Public KeepCache As Boolean = False
Public SubsOnly As Boolean = False
Public VideoFormat As String = ".mp4"
@ -587,11 +588,11 @@ Public Class Main
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
IgnoreS1 = CBool(Integer.Parse(rkg.GetValue("IgnoreS1").ToString))
IgnoreSeason = Integer.Parse(rkg.GetValue("IgnoreS1").ToString)
Catch ex As Exception
Try
Dim rkg As RegistryKey = Registry.CurrentUser.OpenSubKey("Software\CRDownloader")
IgnoreS1 = CBool(Integer.Parse(rkg.GetValue("IgnoreS1").ToString))
IgnoreSeason = Integer.Parse(rkg.GetValue("IgnoreS1").ToString)
Catch ex2 As Exception
End Try
End Try
@ -1746,8 +1747,10 @@ Public Class Main
Dim ffmpeg_command_Builder() As String = ffmpeg_command.Split(New String() {"-c:a copy"}, System.StringSplitOptions.RemoveEmptyEntries)
ffmpeg_command_temp = "-c:a copy" + ffmpeg_command_Builder(1)
End If
Dim CR_Streams As New List(Of CR_Beta_Stream)
Dim CR_series_title As String = Nothing
Dim CR_season_number As String = Nothing
Dim CR_season_number2 As String = Nothing
Dim CR_episode As String = Nothing
Dim CR_episode2 As String = Nothing
Dim CR_Anime_Staffel_int As String = Nothing
@ -1827,11 +1830,8 @@ Public Class Main
'My.Computer.Clipboard.SetText(ObjectJson)
'
CR_Anime_Staffel_int = CR_season_number
If IgnoreS1 = True Then
If CR_season_number = "1" Or CR_season_number = "0" Then
CR_season_number = Nothing
End If
End If
If CR_episode = Nothing And CR_episode2 = Nothing Then
CR_episode_int = "0"
@ -1858,7 +1858,13 @@ Public Class Main
End If
End If
CR_season_number2 = CR_season_number
If IgnoreSeason = 1 And CR_season_number = "1" Or IgnoreSeason = 1 And CR_season_number = "0" Then
CR_season_number = Nothing
ElseIf IgnoreSeason = 2 Then
CR_season_number = Nothing
End If
If Episode_Prefix = "[default episode prefix]" Then
@ -1918,10 +1924,7 @@ Public Class Main
Else
CR_Anime_Staffel_int = "0" + CR_Anime_Staffel_int
End If
'Dim CR_episode_nr As String = CR_episode_int
'If CR_episode_nr.Length = 1 Then
' CR_episode_nr = "0" + CR_episode_nr
'End If
KodiString = KodiString + CR_Anime_Staffel_int + " E" + AddLeadingZeros(CR_episode_int) ' CR_episode_nr
KodiString = KodiString + "] "
CR_FilenName = KodiString + CR_FilenName
@ -1934,7 +1937,7 @@ Public Class Main
CR_FilenName = String.Join(" ", CR_FilenName.Split(invalids, StringSplitOptions.RemoveEmptyEntries)).TrimEnd("."c).Replace(Chr(34), "").Replace("\", "").Replace("/", "") 'System.Text.RegularExpressions.Regex.Replace(CR_FilenName, "[^\w\\-]", " ")
CR_FilenName = RemoveExtraSpaces(CR_FilenName)
'My.Computer.FileSystem.WriteAllText("log.log", WebbrowserText, False)
Pfad2 = UseSubfolder(CR_series_title, CR_season_number, Pfad)
Pfad2 = UseSubfolder(CR_series_title, CR_season_number2, Pfad)
If Not Directory.Exists(Path.GetDirectoryName(Pfad2)) Then
' Nein! Jetzt erstellen...
Try
@ -1961,17 +1964,17 @@ Public Class Main
Debug.WriteLine("error- getting stream data")
Exit Sub
End Try
Dim hls_type As String = Nothing
If CBool(InStr(VideoJson, Chr(34) + "adaptive_hls")) = True Then
hls_type = "adaptive_hls"
ElseIf CBool(InStr(VideoJson, Chr(34) + "multitrack_adaptive_hls_v2")) = True Then
hls_type = "multitrack_adaptive_hls_v2"
ElseIf CBool(InStr(VideoJson, Chr(34) + "vo_adaptive_hls")) = True Then
hls_type = "vo_adaptive_hls"
Else
MsgBox("No download stream avalible", MsgBoxStyle.Critical)
Exit Sub
End If
'Dim hls_type As String = Nothing
'If CBool(InStr(VideoJson, Chr(34) + "adaptive_hls")) = True Then
' hls_type = "adaptive_hls"
'ElseIf CBool(InStr(VideoJson, Chr(34) + "multitrack_adaptive_hls_v2")) = True Then
' hls_type = "multitrack_adaptive_hls_v2"
'ElseIf CBool(InStr(VideoJson, Chr(34) + "vo_adaptive_hls")) = True Then
' hls_type = "vo_adaptive_hls"
'Else
' MsgBox("No download stream avalible", MsgBoxStyle.Critical)
' Exit Sub
'End If
'Me.Invoke(New Action(Function() As Object
' My.Computer.Clipboard.SetText(VideoJson)
' Return Nothing
@ -2055,31 +2058,67 @@ Public Class Main
End If
#End Region
#Region "m3u8 suche"
If CBool(InStr(VideoJson, "audio_locale")) Then
Dim CR_audio As String() = VideoJson.Split(New String() {"audio_locale" + Chr(34) + ":" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)
Dim CR_audio2 As String() = CR_audio(1).Split(New String() {Chr(34) + ","}, System.StringSplitOptions.RemoveEmptyEntries) '(New [Char]() {"-"})
CR_audio_locale = String.Join(" ", CR_audio2(0).Split(invalids, StringSplitOptions.RemoveEmptyEntries)).TrimEnd("."c)
End If
Dim CR_URI_Master As String = Nothing
'If SubsOnly = False Then
Dim ii As Integer = 0
Dim CR_VideoJson As String() = VideoJson.Split(New String() {hls_type}, System.StringSplitOptions.RemoveEmptyEntries)
Dim CR_VideoJsonHardSubs As String() = CR_VideoJson(1).Split(New String() {"hardsub_locale" + Chr(34) + ":" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)
Debug.WriteLine(LangNew)
Debug.WriteLine(CR_VideoJsonHardSubs.Count.ToString)
Dim hls_List As New List(Of String)
For i As Integer = 0 To CR_VideoJsonHardSubs.Count - 1
If LangNew = "" And CR_VideoJsonHardSubs(i).Substring(0, 1) = Chr(34) And CBool(InStr(CR_VideoJsonHardSubs(i), "https://")) Then
CR_URI_Master = CR_VideoJsonHardSubs(i).Replace(LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34), "").Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)(0)
Debug.WriteLine("Nothing+works")
Exit For
ElseIf LangNew IsNot "" And CBool(InStr(CR_VideoJsonHardSubs(i), LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34))) And CBool(InStr(CR_VideoJsonHardSubs(i), "https://")) Then
CR_URI_Master = CR_VideoJsonHardSubs(i).Replace(LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34), "").Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)(0)
Debug.WriteLine("Why are we here again?")
Exit For
End If
VideoJson = CleanJSON(VideoJson)
Dim VideoJObject As JObject = JObject.Parse(VideoJson)
Dim VideoData As List(Of JToken) = VideoJObject.Children().ToList
For Each item As JProperty In VideoData
item.CreateReader()
Select Case item.Name
Case "audio_locale"
Dim Title As String = item.Value.ToString
CR_audio_locale = String.Join(" ", Title.Split(invalids, StringSplitOptions.RemoveEmptyEntries)).TrimEnd("."c).Replace(Chr(34), "").Replace("\", "").Replace("/", "").Replace(":", "")
Case "streams" 'each record is inside the entries array
For Each Entry As JProperty In item.Values
Dim JsonEntryFormat As String = Entry.Name
If CBool(InStr(JsonEntryFormat, "drm")) Or CBool(InStr(JsonEntryFormat, "dash")) Or CBool(InStr(JsonEntryFormat, "download")) Then
Continue For
End If
Dim SubData As List(Of JToken) = Entry.Children().ToList
For Each SubItem As JObject In SubData
SubItem.CreateReader()
Dim StreamFormats As List(Of JToken) = SubItem.Children().ToList
For Each HardsubStreams As JProperty In StreamFormats
HardsubStreams.CreateReader()
Dim SubLang As String = HardsubStreams.Name
Dim Url As String = HardsubStreams.Value("url").ToString
If SubLang = Nothing Or SubLang = "" Then
SubLang = ""
End If
CR_Streams.Add(New CR_Beta_Stream(CR_audio_locale, SubLang, JsonEntryFormat, Url))
Next
Next
Next
End Select
Next
Dim CR_URI_Master As String = Nothing
'Me.Invoke(New Action(Function() As Object
' MsgBox(CR_Streams.Count.ToString + vbNewLine + LangNew)
' Return Nothing
' End Function))
For i As Integer = 0 To CR_Streams.Count - 1
Debug.WriteLine(CR_Streams.Item(i).subLang)
If CR_Streams.Item(i).subLang = LangNew Then
CR_URI_Master = CR_Streams.Item(i).Url
End If
Next
If CR_URI_Master = Nothing Then
Me.Invoke(New Action(Function() As Object
ResoNotFoundString = VideoJson
@ -2092,12 +2131,15 @@ Public Class Main
Else
LangNew = ResoBackString
ResoBackString = Nothing
For i As Integer = 0 To CR_VideoJsonHardSubs.Count - 1
If CBool(InStr(CR_VideoJsonHardSubs(i), LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34))) Then
CR_URI_Master = CR_VideoJsonHardSubs(i).Replace(LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34), "").Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)(0)
Exit For
For i As Integer = 0 To CR_Streams.Count - 1
Debug.WriteLine(CR_Streams.Item(i).subLang)
If CR_Streams.Item(i).subLang = LangNew Then
CR_URI_Master = CR_Streams.Item(i).Url
End If
Next
End If
End If
CR_URI_Master = CR_URI_Master.Replace("&", "&").Replace("/u0026", "&").Replace("\u002F", "/").Replace("\u0026", "&")
@ -2317,6 +2359,7 @@ Public Class Main
Dim ffmpeg_command_Builder() As String = ffmpeg_command.Split(New String() {"-c:a copy"}, System.StringSplitOptions.RemoveEmptyEntries)
ffmpeg_command_temp = "-c:a copy" + ffmpeg_command_Builder(1)
End If
Dim CR_Streams As New List(Of CR_Beta_Stream)
Dim CR_series_title As String = Nothing
Dim CR_season_number As String = Nothing
Dim CR_episode As String = Nothing
@ -2388,10 +2431,10 @@ Public Class Main
'My.Computer.Clipboard.SetText(ObjectJson)
'
CR_Anime_Staffel_int = CR_season_number
If IgnoreS1 = True Then
If CR_season_number = "1" Or CR_season_number = "0" Then
CR_season_number = Nothing
End If
If IgnoreSeason = 1 And CR_season_number = "1" Or IgnoreSeason = 1 And CR_season_number = "0" Then
CR_season_number = Nothing
ElseIf IgnoreSeason = 2 Then
CR_season_number = Nothing
End If
CR_episode_int = CR_episode
If Season_Prefix = "[default season prefix]" Then
@ -2497,19 +2540,7 @@ Public Class Main
Debug.WriteLine("error- getting stream data")
Exit Sub
End Try
Dim hls_type As String = Nothing
If CBool(InStr(VideoJson, Chr(34) + "adaptive_hls")) = True Then
hls_type = "adaptive_hls"
ElseIf CBool(InStr(VideoJson, Chr(34) + "multitrack_adaptive_hls_v2")) = True Then
hls_type = "multitrack_adaptive_hls_v2"
ElseIf CBool(InStr(VideoJson, Chr(34) + "vo_adaptive_hls")) = True Then
hls_type = "vo_adaptive_hls"
Else
MsgBox("No download stream avalible", MsgBoxStyle.Critical)
Exit Sub
End If
'My.Computer.Clipboard.SetText(VideoJson)
'MsgBox(SubSprache)
Dim LangNew As String = ConvertCC(SubSprache)
#End Region
#Region "Download softsub file or build ffmpeg cmd"
@ -2586,45 +2617,62 @@ Public Class Main
End If
#End Region
#Region "m3u8 suche"
If CBool(InStr(VideoJson, "audio_locale")) Then
Dim CR_audio As String() = VideoJson.Split(New String() {"audio_locale" + Chr(34) + ":" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)
Dim CR_audio2 As String() = CR_audio(1).Split(New String() {Chr(34) + ","}, System.StringSplitOptions.RemoveEmptyEntries) '(New [Char]() {"-"})
CR_audio_locale = String.Join(" ", CR_audio2(0).Split(invalids, StringSplitOptions.RemoveEmptyEntries)).TrimEnd("."c)
End If
Dim CR_URI_Master As String = Nothing
'If SubsOnly = False Then
Dim ii As Integer = 0
Dim CR_VideoJson As String() = VideoJson.Split(New String() {hls_type}, System.StringSplitOptions.RemoveEmptyEntries)
Dim CR_VideoJsonHardSubs As String() = CR_VideoJson(1).Split(New String() {"hardsub_locale" + Chr(34) + ":" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)
Debug.WriteLine(LangNew)
Debug.WriteLine(CR_VideoJsonHardSubs.Count.ToString)
Dim hls_List As New List(Of String)
For i As Integer = 0 To CR_VideoJsonHardSubs.Count - 1
If CBool(InStr(CR_VideoJsonHardSubs(i), LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34))) Then
CR_URI_Master = CR_VideoJsonHardSubs(i).Replace(LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34), "").Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)(0)
Exit For
End If
VideoJson = CleanJSON(VideoJson)
Dim VideoJObject As JObject = JObject.Parse(VideoJson)
Dim VideoData As List(Of JToken) = VideoJObject.Children().ToList
For Each item As JProperty In VideoData
item.CreateReader()
Select Case item.Name
Case "audio_locale"
Dim Title As String = item.Value.ToString
CR_audio_locale = String.Join(" ", Title.Split(invalids, StringSplitOptions.RemoveEmptyEntries)).TrimEnd("."c).Replace(Chr(34), "").Replace("\", "").Replace("/", "").Replace(":", "")
Case "streams" 'each record is inside the entries array
For Each Entry As JProperty In item.Values
Dim JsonEntryFormat As String = Entry.Name
If CBool(InStr(JsonEntryFormat, "drm")) Or CBool(InStr(JsonEntryFormat, "dash")) Or CBool(InStr(JsonEntryFormat, "download")) Then
Continue For
End If
Dim SubData As List(Of JToken) = Entry.Children().ToList
For Each SubItem As JObject In SubData
SubItem.CreateReader()
Dim StreamFormats As List(Of JToken) = SubItem.Children().ToList
For Each HardsubStreams As JProperty In StreamFormats
HardsubStreams.CreateReader()
Dim SubLang As String = HardsubStreams.Name
Dim Url As String = HardsubStreams.Value.ToString
If SubLang = Nothing Or SubLang = "" Then
SubLang = "null"
End If
CR_Streams.Add(New CR_Beta_Stream(CR_audio_locale, SubLang, JsonEntryFormat, Url))
Next
Next
Next
End Select
Next
If CR_URI_Master = Nothing Then
Me.Invoke(New Action(Function() As Object
ResoNotFoundString = VideoJson
DialogTaskString = "Language_CR_Beta"
ErrorDialog.ShowDialog()
Return Nothing
End Function))
If UserCloseDialog = True Then
Throw New System.Exception(Chr(34) + "UserAbort" + Chr(34))
Else
LangNew = ResoBackString
ResoBackString = Nothing
For i As Integer = 0 To CR_VideoJsonHardSubs.Count - 1
If CBool(InStr(CR_VideoJsonHardSubs(i), LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34))) Then
CR_URI_Master = CR_VideoJsonHardSubs(i).Replace(LangNew + Chr(34) + "," + Chr(34) + "url" + Chr(34) + ":" + Chr(34), "").Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries)(0)
Exit For
End If
Next
Dim CR_URI_Master As String = Nothing
For i As Integer = 0 To CR_Streams.Count - 1
If CR_Streams.Item(i).subLang = LangNew Then
Debug.WriteLine(CR_Streams.Item(i).subLang)
CR_URI_Master = CR_Streams.Item(i).Url
End If
End If
Next
CR_URI_Master = CR_URI_Master.Replace("&", "&").Replace("/u0026", "&").Replace("\u002F", "/").Replace("\u0026", "&")
If CBool(InStr(CR_URI_Master, "master.m3u8")) Then
Me.Invoke(New Action(Function() As Object
@ -5302,6 +5350,23 @@ Public Class FunimationStream
End Function
End Class
Public Class CR_Beta_Stream
Public audioLanguage As String
Public Url As String
Public subLang As String
Public Format As String
Public Sub New(ByVal audioLanguage As String, ByVal subLang As String, ByVal Format As String, ByVal Url As String)
Me.subLang = subLang
Me.Url = Url
Me.audioLanguage = audioLanguage
Me.Format = Format
End Sub
Public Overrides Function ToString() As String
Return String.Format("{0}, {1}, {2}", Me.audioLanguage, Me.subLang, Me.Format, Me.Url)
End Function
End Class
Public Class ServerResponse
Public Type As String

View File

@ -44,6 +44,8 @@ Partial Class Einstellungen
Me.GroupBox18 = New System.Windows.Forms.GroupBox()
Me.ListViewAdd_True = New MetroFramework.Controls.MetroCheckBox()
Me.GroupBox16 = New System.Windows.Forms.GroupBox()
Me.MetroLabel3 = New MetroFramework.Controls.MetroLabel()
Me.TempTB = New MetroFramework.Controls.MetroTextBox()
Me.DD_DLMode = New MetroFramework.Controls.MetroComboBox()
Me.GroupBox4 = New System.Windows.Forms.GroupBox()
Me.MergeMP4 = New MetroFramework.Controls.MetroCheckBox()
@ -109,7 +111,6 @@ Partial Class Einstellungen
Me.CB_SoftSubSettings = New MetroFramework.Controls.MetroComboBox()
Me.GB_Filename_Pre = New System.Windows.Forms.GroupBox()
Me.KodiSupport = New MetroFramework.Controls.MetroToggle()
Me.IgnoreS1 = New MetroFramework.Controls.MetroCheckBox()
Me.MetroLink1 = New MetroFramework.Controls.MetroLink()
Me.GroupBox12 = New System.Windows.Forms.GroupBox()
Me.DD_Episode_Prefix = New MetroFramework.Controls.MetroComboBox()
@ -145,8 +146,7 @@ Partial Class Einstellungen
Me.Label5 = New MetroFramework.Controls.MetroLabel()
Me.BackgroundWorker1 = New System.ComponentModel.BackgroundWorker()
Me.Btn_Save = New System.Windows.Forms.Button()
Me.MetroLabel3 = New MetroFramework.Controls.MetroLabel()
Me.TempTB = New MetroFramework.Controls.MetroTextBox()
Me.CB_Ignore = New MetroFramework.Controls.MetroComboBox()
CType(Me.pictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
Me.GroupBox14.SuspendLayout()
Me.SoftSubs.SuspendLayout()
@ -449,6 +449,50 @@ Partial Class Einstellungen
Me.GroupBox16.TabStop = False
Me.GroupBox16.Text = "Download Mode"
'
'MetroLabel3
'
Me.MetroLabel3.FontWeight = MetroFramework.MetroLabelWeight.Regular
Me.MetroLabel3.Location = New System.Drawing.Point(6, 64)
Me.MetroLabel3.Name = "MetroLabel3"
Me.MetroLabel3.Size = New System.Drawing.Size(469, 22)
Me.MetroLabel3.TabIndex = 19
Me.MetroLabel3.Text = "Temporary Folder"
Me.MetroLabel3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'TempTB
'
'
'
'
Me.TempTB.CustomButton.Image = Nothing
Me.TempTB.CustomButton.Location = New System.Drawing.Point(445, 1)
Me.TempTB.CustomButton.Name = ""
Me.TempTB.CustomButton.Size = New System.Drawing.Size(23, 23)
Me.TempTB.CustomButton.Style = MetroFramework.MetroColorStyle.Blue
Me.TempTB.CustomButton.TabIndex = 1
Me.TempTB.CustomButton.Theme = MetroFramework.MetroThemeStyle.Light
Me.TempTB.CustomButton.UseSelectable = True
Me.TempTB.CustomButton.Visible = False
Me.TempTB.FontSize = MetroFramework.MetroTextBoxSize.Medium
Me.TempTB.Lines = New String() {"https://www.crunchyroll.com/"}
Me.TempTB.Location = New System.Drawing.Point(6, 90)
Me.TempTB.MaxLength = 32767
Me.TempTB.Name = "TempTB"
Me.TempTB.PasswordChar = Global.Microsoft.VisualBasic.ChrW(0)
Me.TempTB.ReadOnly = True
Me.TempTB.ScrollBars = System.Windows.Forms.ScrollBars.None
Me.TempTB.SelectedText = ""
Me.TempTB.SelectionLength = 0
Me.TempTB.SelectionStart = 0
Me.TempTB.ShortcutsEnabled = True
Me.TempTB.Size = New System.Drawing.Size(469, 25)
Me.TempTB.TabIndex = 20
Me.TempTB.Text = "https://www.crunchyroll.com/"
Me.TempTB.TextAlign = System.Windows.Forms.HorizontalAlignment.Center
Me.TempTB.UseSelectable = True
Me.TempTB.WaterMarkColor = System.Drawing.Color.FromArgb(CType(CType(109, Byte), Integer), CType(CType(109, Byte), Integer), CType(CType(109, Byte), Integer))
Me.TempTB.WaterMarkFont = New System.Drawing.Font("Segoe UI", 12.0!, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Pixel)
'
'DD_DLMode
'
Me.DD_DLMode.DropDownHeight = 250
@ -545,43 +589,43 @@ Partial Class Einstellungen
'ListC1
'
Me.ListC1.Name = "ListC1"
Me.ListC1.Size = New System.Drawing.Size(172, 22)
Me.ListC1.Size = New System.Drawing.Size(180, 22)
Me.ListC1.Text = "-c copy"
'
'ListC2
'
Me.ListC2.Name = "ListC2"
Me.ListC2.Size = New System.Drawing.Size(172, 22)
Me.ListC2.Size = New System.Drawing.Size(180, 22)
Me.ListC2.Text = "-c:v h264_nvenc "
'
'ListC3
'
Me.ListC3.Name = "ListC3"
Me.ListC3.Size = New System.Drawing.Size(172, 22)
Me.ListC3.Size = New System.Drawing.Size(180, 22)
Me.ListC3.Text = "-c:v hevc_nvenc"
'
'ListC4
'
Me.ListC4.Name = "ListC4"
Me.ListC4.Size = New System.Drawing.Size(172, 22)
Me.ListC4.Size = New System.Drawing.Size(180, 22)
Me.ListC4.Text = "-c:v libx264"
'
'ListC5
'
Me.ListC5.Name = "ListC5"
Me.ListC5.Size = New System.Drawing.Size(172, 22)
Me.ListC5.Size = New System.Drawing.Size(180, 22)
Me.ListC5.Text = "-c:v libx265"
'
'ListC6
'
Me.ListC6.Name = "ListC6"
Me.ListC6.Size = New System.Drawing.Size(172, 22)
Me.ListC6.Size = New System.Drawing.Size(180, 22)
Me.ListC6.Text = "-c:v h264_amf"
'
'ListC7
'
Me.ListC7.Name = "ListC7"
Me.ListC7.Size = New System.Drawing.Size(172, 22)
Me.ListC7.Size = New System.Drawing.Size(180, 22)
Me.ListC7.Text = "-c:v hevc_amf"
'
'FFMPEG_CommandP2
@ -799,10 +843,10 @@ Partial Class Einstellungen
Me.TabPage1.HorizontalScrollbarBarColor = True
Me.TabPage1.HorizontalScrollbarHighlightOnWheel = False
Me.TabPage1.HorizontalScrollbarSize = 10
Me.TabPage1.Location = New System.Drawing.Point(4, 44)
Me.TabPage1.Location = New System.Drawing.Point(4, 35)
Me.TabPage1.Name = "TabPage1"
Me.TabPage1.Padding = New System.Windows.Forms.Padding(3)
Me.TabPage1.Size = New System.Drawing.Size(501, 519)
Me.TabPage1.Size = New System.Drawing.Size(501, 528)
Me.TabPage1.TabIndex = 0
Me.TabPage1.Text = " Main"
Me.TabPage1.VerticalScrollbar = True
@ -1042,7 +1086,7 @@ Partial Class Einstellungen
Me.TabControl1.FontWeight = MetroFramework.MetroTabControlWeight.Regular
Me.TabControl1.Location = New System.Drawing.Point(22, 60)
Me.TabControl1.Name = "TabControl1"
Me.TabControl1.SelectedIndex = 1
Me.TabControl1.SelectedIndex = 2
Me.TabControl1.Size = New System.Drawing.Size(509, 567)
Me.TabControl1.TabIndex = 0
Me.TabControl1.UseSelectable = True
@ -1056,9 +1100,9 @@ Partial Class Einstellungen
Me.MetroTabPage2.HorizontalScrollbarBarColor = True
Me.MetroTabPage2.HorizontalScrollbarHighlightOnWheel = False
Me.MetroTabPage2.HorizontalScrollbarSize = 10
Me.MetroTabPage2.Location = New System.Drawing.Point(4, 35)
Me.MetroTabPage2.Location = New System.Drawing.Point(4, 44)
Me.MetroTabPage2.Name = "MetroTabPage2"
Me.MetroTabPage2.Size = New System.Drawing.Size(501, 528)
Me.MetroTabPage2.Size = New System.Drawing.Size(501, 519)
Me.MetroTabPage2.TabIndex = 8
Me.MetroTabPage2.Text = "Naming"
Me.MetroTabPage2.VerticalScrollbarBarColor = True
@ -1137,8 +1181,8 @@ Partial Class Einstellungen
'GB_Filename_Pre
'
Me.GB_Filename_Pre.BackColor = System.Drawing.Color.Transparent
Me.GB_Filename_Pre.Controls.Add(Me.CB_Ignore)
Me.GB_Filename_Pre.Controls.Add(Me.KodiSupport)
Me.GB_Filename_Pre.Controls.Add(Me.IgnoreS1)
Me.GB_Filename_Pre.Controls.Add(Me.MetroLink1)
Me.GB_Filename_Pre.Font = New System.Drawing.Font("Arial", 9.75!)
Me.GB_Filename_Pre.ForeColor = System.Drawing.Color.Black
@ -1159,17 +1203,6 @@ Partial Class Einstellungen
Me.KodiSupport.Text = "Aus"
Me.KodiSupport.UseSelectable = True
'
'IgnoreS1
'
Me.IgnoreS1.AutoSize = True
Me.IgnoreS1.FontSize = MetroFramework.MetroCheckBoxSize.Medium
Me.IgnoreS1.Location = New System.Drawing.Point(250, 27)
Me.IgnoreS1.Name = "IgnoreS1"
Me.IgnoreS1.Size = New System.Drawing.Size(227, 19)
Me.IgnoreS1.TabIndex = 19
Me.IgnoreS1.Text = "ignore Season 1 for the file name"
Me.IgnoreS1.UseSelectable = True
'
'MetroLink1
'
Me.MetroLink1.FontSize = MetroFramework.MetroLinkSize.Medium
@ -1269,10 +1302,10 @@ Partial Class Einstellungen
Me.TabPage6.HorizontalScrollbarBarColor = True
Me.TabPage6.HorizontalScrollbarHighlightOnWheel = False
Me.TabPage6.HorizontalScrollbarSize = 10
Me.TabPage6.Location = New System.Drawing.Point(4, 44)
Me.TabPage6.Location = New System.Drawing.Point(4, 35)
Me.TabPage6.Name = "TabPage6"
Me.TabPage6.Padding = New System.Windows.Forms.Padding(3)
Me.TabPage6.Size = New System.Drawing.Size(501, 519)
Me.TabPage6.Size = New System.Drawing.Size(501, 528)
Me.TabPage6.TabIndex = 4
Me.TabPage6.Text = " Funimation"
Me.TabPage6.VerticalScrollbarBarColor = True
@ -1640,49 +1673,19 @@ Partial Class Einstellungen
Me.Btn_Save.TabIndex = 9
Me.Btn_Save.UseVisualStyleBackColor = False
'
'MetroLabel3
'CB_Ignore
'
Me.MetroLabel3.FontWeight = MetroFramework.MetroLabelWeight.Regular
Me.MetroLabel3.Location = New System.Drawing.Point(6, 64)
Me.MetroLabel3.Name = "MetroLabel3"
Me.MetroLabel3.Size = New System.Drawing.Size(469, 22)
Me.MetroLabel3.TabIndex = 19
Me.MetroLabel3.Text = "Temporary Folder"
Me.MetroLabel3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'TempTB
'
'
'
'
Me.TempTB.CustomButton.Image = Nothing
Me.TempTB.CustomButton.Location = New System.Drawing.Point(445, 1)
Me.TempTB.CustomButton.Name = ""
Me.TempTB.CustomButton.Size = New System.Drawing.Size(23, 23)
Me.TempTB.CustomButton.Style = MetroFramework.MetroColorStyle.Blue
Me.TempTB.CustomButton.TabIndex = 1
Me.TempTB.CustomButton.Theme = MetroFramework.MetroThemeStyle.Light
Me.TempTB.CustomButton.UseSelectable = True
Me.TempTB.CustomButton.Visible = False
Me.TempTB.FontSize = MetroFramework.MetroTextBoxSize.Medium
Me.TempTB.Lines = New String() {"https://www.crunchyroll.com/"}
Me.TempTB.Location = New System.Drawing.Point(6, 90)
Me.TempTB.MaxLength = 32767
Me.TempTB.Name = "TempTB"
Me.TempTB.PasswordChar = Global.Microsoft.VisualBasic.ChrW(0)
Me.TempTB.ReadOnly = True
Me.TempTB.ScrollBars = System.Windows.Forms.ScrollBars.None
Me.TempTB.SelectedText = ""
Me.TempTB.SelectionLength = 0
Me.TempTB.SelectionStart = 0
Me.TempTB.ShortcutsEnabled = True
Me.TempTB.Size = New System.Drawing.Size(469, 25)
Me.TempTB.TabIndex = 20
Me.TempTB.Text = "https://www.crunchyroll.com/"
Me.TempTB.TextAlign = System.Windows.Forms.HorizontalAlignment.Center
Me.TempTB.UseSelectable = True
Me.TempTB.WaterMarkColor = System.Drawing.Color.FromArgb(CType(CType(109, Byte), Integer), CType(CType(109, Byte), Integer), CType(CType(109, Byte), Integer))
Me.TempTB.WaterMarkFont = New System.Drawing.Font("Segoe UI", 12.0!, System.Drawing.FontStyle.Italic, System.Drawing.GraphicsUnit.Pixel)
Me.CB_Ignore.DropDownHeight = 250
Me.CB_Ignore.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.75!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.CB_Ignore.FormattingEnabled = True
Me.CB_Ignore.IntegralHeight = False
Me.CB_Ignore.ItemHeight = 23
Me.CB_Ignore.Items.AddRange(New Object() {"[Default] use season numbers", "ignore Season 1", "ignore all season numbers"})
Me.CB_Ignore.Location = New System.Drawing.Point(248, 21)
Me.CB_Ignore.Name = "CB_Ignore"
Me.CB_Ignore.Size = New System.Drawing.Size(225, 29)
Me.CB_Ignore.TabIndex = 40
Me.CB_Ignore.UseSelectable = True
'
'Einstellungen
'
@ -1866,7 +1869,6 @@ Partial Class Einstellungen
Friend WithEvents MetroLink1 As MetroFramework.Controls.MetroLink
Friend WithEvents GroupBox12 As GroupBox
Friend WithEvents LeadingZeroDD As MetroFramework.Controls.MetroComboBox
Friend WithEvents IgnoreS1 As MetroFramework.Controls.MetroCheckBox
Friend WithEvents DD_Episode_Prefix As MetroFramework.Controls.MetroComboBox
Friend WithEvents DD_Season_Prefix As MetroFramework.Controls.MetroComboBox
Friend WithEvents CR_Filename As MetroFramework.Controls.MetroComboBox
@ -1878,4 +1880,5 @@ Partial Class Einstellungen
Friend WithEvents ListViewAdd_True As MetroFramework.Controls.MetroCheckBox
Friend WithEvents MetroLabel3 As MetroFramework.Controls.MetroLabel
Friend WithEvents TempTB As MetroFramework.Controls.MetroTextBox
Friend WithEvents CB_Ignore As MetroFramework.Controls.MetroComboBox
End Class

View File

@ -37,9 +37,7 @@ Public Class Einstellungen
Bitrate_Funi.SelectedIndex = Main.Funimation_Bitrate
If Main.IgnoreS1 = True Then
IgnoreS1.Checked = True
End If
CB_Ignore.SelectedIndex = Main.IgnoreSeason
If Main.IncludeLangName = True Then
CB_SoftSubSettings.SelectedIndex = 1
@ -380,15 +378,11 @@ Public Class Einstellungen
If IgnoreS1.Checked = True Then
Main.IgnoreS1 = True
rk.SetValue("IgnoreS1", 1, RegistryValueKind.String)
Else
Main.IgnoreS1 = False
rk.SetValue("IgnoreS1", 0, RegistryValueKind.String)
End If
Main.IgnoreSeason = CB_Ignore.SelectedIndex
rk.SetValue("IgnoreS1", CB_Ignore.SelectedIndex, RegistryValueKind.String)
If KodiSupport.Checked = True Then
Main.KodiNaming = True