diff --git a/.vs/Crunchyroll Downloader/v15/.suo b/.vs/Crunchyroll Downloader/v15/.suo index 2ff1dd3..6a88fc6 100644 Binary files a/.vs/Crunchyroll Downloader/v15/.suo and b/.vs/Crunchyroll Downloader/v15/.suo differ diff --git a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide index 8242ad1..bea0d5e 100644 Binary files a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide and b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide differ diff --git a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm index 4a6903f..756f766 100644 Binary files a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm and b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-shm differ diff --git a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal index c9e8114..c46e19f 100644 Binary files a/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal and b/.vs/Crunchyroll Downloader/v15/Server/sqlite3/storage.ide-wal differ diff --git a/Crunchyroll Downloader/CRD_List_Item.vb b/Crunchyroll Downloader/CRD_List_Item.vb index da7612b..a95c27b 100644 --- a/Crunchyroll Downloader/CRD_List_Item.vb +++ b/Crunchyroll Downloader/CRD_List_Item.vb @@ -266,7 +266,13 @@ Public Class CRD_List_Item Dim wc_ts As New WebClient wc_ts.DownloadFile(New Uri(DL_URL), DL_Pfad) Catch ex As Exception - Debug.WriteLine(ex.ToString + vbNewLine + DL_Pfad + vbNewLine + DL_URL) + Try + Dim wc_ts As New WebClient + wc_ts.DownloadFile(New Uri(DL_URL), DL_Pfad) + Catch ex2 As Exception + Debug.WriteLine("Download error #2: " + DL_Pfad + vbNewLine + ex.ToString + vbNewLine + DL_URL) + End Try + Debug.WriteLine("Download error #1: " + DL_Pfad) End Try End Sub @@ -357,6 +363,9 @@ Public Class CRD_List_Item End If + Dim LoadedKeys As New List(Of String) + LoadedKeys.Add("Nothing") + Dim KeyFileCache As String = Nothing Dim textLenght() As String = text.Split(New String() {vbLf}, System.StringSplitOptions.RemoveEmptyEntries) Dim Fragments() As String = text.Split(New String() {".ts"}, System.StringSplitOptions.RemoveEmptyEntries) Dim FragmentsInt As Integer = Fragments.Count - 2 @@ -448,6 +457,27 @@ Public Class CRD_List_Item ElseIf InStr(textLenght(i), "URI=" + Chr(34)) Then Dim KeyLine As String = textLenght(i) If InStr(KeyLine, "https://") Then + + Dim KeyFile() As String = KeyLine.Split(New String() {"URI=" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries) + Dim KeyFile2() As String = KeyFile(1).Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries) + If LoadedKeys.Item(LoadedKeys.Count - 1) = KeyFile2(0) Then + Else + Dim KeyClient As New WebClient + KeyClient.Encoding = Encoding.UTF8 + If Main.WebbrowserCookie = Nothing Then + Else + KeyClient.Headers.Add(HttpRequestHeader.Cookie, Main.WebbrowserCookie) + End If + Dim KeyFile3 As String = einstellungen.GeräteID() + ".key" + KeyFileCache = KeyFile3 + KeyClient.DownloadFile(KeyFile2(0), Application.StartupPath + "\" + KeyFile3) + LoadedKeys.Add(KeyFile2(0)) + End If + If KeyFile2.Count > 1 Then + KeyLine = KeyFile(0) + "URI=" + Chr(34) + KeyFileCache + Chr(34) + KeyFile2(1) + Else + KeyLine = KeyFile(0) + "URI=" + Chr(34) + KeyFileCache + Chr(34) + End If 'ElseIf InStr(KeyLine, "../") Then ' Dim countDot() As String = KeyLine.Split(New String() {"./"}, System.StringSplitOptions.RemoveEmptyEntries) @@ -457,6 +487,7 @@ Public Class CRD_List_Item ' path = path + c(i3) ' Next ' KeyLine = path + countDot(countDot.Count - 1) + Else Dim c() As String = New Uri(m3u8_url_3).Segments Dim path As String = "https://" + New Uri(m3u8_url_3).Host @@ -464,7 +495,26 @@ Public Class CRD_List_Item path = path + c(i3) Next KeyLine = KeyLine.Replace("URI=" + Chr(34), "URI=" + Chr(34) + path) 'path + textLenght(i) - Debug.WriteLine(vbNewLine + KeyLine) + Dim KeyFile() As String = KeyLine.Split(New String() {"URI=" + Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries) + Dim KeyFile2() As String = KeyFile(1).Split(New String() {Chr(34)}, System.StringSplitOptions.RemoveEmptyEntries) + If LoadedKeys.Item(LoadedKeys.Count - 1) = KeyFile2(0) Then + Else + Dim KeyClient As New WebClient + KeyClient.Encoding = Encoding.UTF8 + If Main.WebbrowserCookie = Nothing Then + Else + KeyClient.Headers.Add(HttpRequestHeader.Cookie, Main.WebbrowserCookie) + End If + Dim KeyFile3 As String = einstellungen.GeräteID() + ".key" + KeyFileCache = KeyFile3 + KeyClient.DownloadFile(KeyFile2(0), Application.StartupPath + "\" + KeyFile3) + LoadedKeys.Add(KeyFile2(0)) + End If + If KeyFile2.Count > 1 Then + KeyLine = KeyFile(0) + "URI=" + Chr(34) + KeyFileCache + Chr(34) + KeyFile2(1) + Else + KeyLine = KeyFile(0) + "URI=" + Chr(34) + KeyFileCache + Chr(34) + End If End If m3u8FFmpeg = m3u8FFmpeg + KeyLine + vbLf Else @@ -492,7 +542,7 @@ Public Class CRD_List_Item Dim exepath As String = Application.StartupPath + "\ffmpeg.exe" Dim startinfo As New System.Diagnostics.ProcessStartInfo - Dim cmd As String = "-protocol_whitelist file,crypto,http,https,tcp,tls " + DL_URL + " " + DL_Pfad '+ " " + ffmpeg_command + " " + DL_Pfad 'start ffmpeg with command strFFCMD string + Dim cmd As String = "-allowed_extensions ALL " + DL_URL + " " + DL_Pfad '+ " " + ffmpeg_command + " " + DL_Pfad 'start ffmpeg with command strFFCMD string If Debug2 = True Then MsgBox(cmd) @@ -656,6 +706,7 @@ Public Class CRD_List_Item Return Nothing End Function)) If HybridMode = True Then + Thread.Sleep(1000) System.IO.Directory.Delete(HybridModePath, True) End If End If diff --git a/Crunchyroll Downloader/Main.vb b/Crunchyroll Downloader/Main.vb index bf038d0..9c13243 100644 --- a/Crunchyroll Downloader/Main.vb +++ b/Crunchyroll Downloader/Main.vb @@ -2273,12 +2273,12 @@ Public Class Main UsedSub = SubTitle2(SubTitle2.Count - 1) + ".dfxp" Else If MessageBox.Show("No Subtitle found in the website, a logfile was created." + vbNewLine + "Press 'Yes' to download the video without subtitle", "No Subtitle", MessageBoxButtons.YesNo) = DialogResult.Yes Then - File.WriteAllText(Path.Combine(Application.StartupPath + "No Subtitle for" + DownloadPfad.Replace(".mp4", ".log")), PlayerPage, Encoding.UTF8) + File.WriteAllText(DownloadPfad.Replace(".mp4", "-no subtitle.log"), PlayerPage, Encoding.UTF8) Else - File.WriteAllText(Path.Combine(Application.StartupPath + "No Subtitle for" + DownloadPfad.Replace(".mp4", ".log")), PlayerPage, Encoding.UTF8) + File.WriteAllText(DownloadPfad.Replace(".mp4", "-no subtitle.log"), PlayerPage, Encoding.UTF8) Exit Sub End If - 'MsgBox("No Subtitle found in the website, a logfile was created.", MsgBoxStyle.OkCancel, "No Subtitle") + 'MsgBox("No Subtitle found In the website, a logfile was created.", MsgBoxStyle.OkCancel, "No Subtitle") End If Else @@ -2308,9 +2308,9 @@ Public Class Main UsedSub = Subs_in_dfxp.Item(0) End If End If - - If MergeSubstoMP4 = True Then - If HardSubFunimation = True Then + If UsedSub = Nothing Then + ElseIf MergeSubstoMP4 = True Then + If HardSubFunimation = True Then Dim SubText As String = client0.DownloadString(UsedSub) Dim SubtitelFormat As String = ".srt" If InStr(UsedSub, ".vtt") Then @@ -2350,7 +2350,15 @@ Public Class Main #End Region #Region "SubsToMP4" - If HardSubFunimation = True Then + If UsedSub = Nothing Then + If FunimationDub = "japanese" Then + Dim DubMetatata As String = " -metadata:s:a:0 language=jpn" + Funimation_m3u8_final = "-i " + Chr(34) + Funimation_m3u8_final + Chr(34) + DubMetatata + " " + ffmpeg_command + Else + Dim DubMetatata As String = " -metadata:s:a:0 language=eng" + Funimation_m3u8_final = "-i " + Chr(34) + Funimation_m3u8_final + Chr(34) + DubMetatata + " " + ffmpeg_command + End If + ElseIf HardSubFunimation = True Then Dim ffmpeg_hardsub As String = Nothing If InStr(ffmpeg_command, "-c copy") Then ffmpeg_hardsub = "-bsf:a aac_adtstoasc" diff --git a/Crunchyroll Downloader/My Project/AssemblyInfo.vb b/Crunchyroll Downloader/My Project/AssemblyInfo.vb index 9401bf4..33c5c44 100644 --- a/Crunchyroll Downloader/My Project/AssemblyInfo.vb +++ b/Crunchyroll Downloader/My Project/AssemblyInfo.vb @@ -32,6 +32,6 @@ Imports System.Runtime.InteropServices ' übernehmen, indem Sie "*" eingeben: ' - - + + diff --git a/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.exe b/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.exe index eeacc07..a81a0f3 100644 Binary files a/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.exe and b/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.exe differ diff --git a/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.pdb b/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.pdb index 6e524f5..0a39086 100644 Binary files a/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.pdb and b/Crunchyroll Downloader/bin/x86/Debug/Crunchyroll Downloader.pdb differ diff --git a/Crunchyroll Downloader/bin/x86/Debug/WebInterface/index.html b/Crunchyroll Downloader/bin/x86/Debug/WebInterface/index.html index f5707b3..23c3853 100644 --- a/Crunchyroll Downloader/bin/x86/Debug/WebInterface/index.html +++ b/Crunchyroll Downloader/bin/x86/Debug/WebInterface/index.html @@ -28,6 +28,34 @@ image error +
+ +image error + +
+ +Overlord
Season 1 Episode 1
+ +
+ +
+ +
+Finished - 1439,81MB +
+
+1080p + + image errornull + +
+ +
+ +
+ +image error