fix: Fix ffmpeg

This commit is contained in:
Myzel394 2023-11-30 23:20:48 +01:00
parent 0d618380fa
commit 3cee858b56
No known key found for this signature in database
GPG Key ID: 79CC92F37B3E1A2B
2 changed files with 7 additions and 3 deletions

View File

@ -138,14 +138,15 @@ abstract class BatchesFolder(
filePaths,
outputFile,
parameter,
)
).await()
return outputFile
} catch (e: MediaConverter.FFmpegException) {
continue
}
}
}
return outputFile
throw MediaConverter.FFmpegException("Failed to concatenate")
}
fun exportFolderForSettings(): String {

View File

@ -70,13 +70,16 @@ class MediaConverter {
" -safe 0" +
" -i ${listFile.absolutePath}" +
extraCommand +
" -strict normal" +
" -y" +
" $outputFile"
FFmpegKit.executeAsync(
command
) { session ->
listFile.delete()
runCatching {
listFile.delete()
}
if (!ReturnCode.isSuccess(session!!.returnCode)) {
Log.d(