SHA256
Add Force Software Encoder Feature
This commit is contained in:
5 files changed
+33
-10
No files matched your search
+9
-2
@@ -1,5 +1,6 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
using System.Linq;
|
||||
using System.Text.RegularExpressions;
|
||||
using ADOFAIRenderer.Util.FFmpeg;
|
||||
using MelonLoader;
|
||||
@@ -130,12 +131,18 @@ namespace ADOFAIRenderer.Util
|
||||
return null;
|
||||
}
|
||||
|
||||
public static List<string> GetPrioritizedEncoderCandidates(Codec codec)
|
||||
public static List<string> GetPrioritizedEncoderCandidates(Codec codec, bool forceSoftware = false)
|
||||
{
|
||||
if (!CodecMap.TryGetValue(codec, out var list)) return new List<string>();
|
||||
|
||||
var vendor = GetActiveGPUVendor();
|
||||
var prioritized = new List<string>();
|
||||
if (forceSoftware)
|
||||
{
|
||||
prioritized.AddRange(from item in list where item.Item1 == GPUVendor.Unknown select item.Item2);
|
||||
return prioritized;
|
||||
}
|
||||
|
||||
var vendor = GetActiveGPUVendor();
|
||||
var others = new List<string>();
|
||||
|
||||
foreach (var item in list)
|
||||
|
||||
Reference in new issue
Block a user