This commit is contained in:
copecone committed 2026-06-12 12:30:58 +09:00
1 parent 382e8eef80
commit 2b8e2c0c71
10 files changed
+27 -13

No files matched your search

+1 -1
View File
@@ -13,7 +13,7 @@ namespace ADOFAIRenderer.Util
public static int TotalSamples { get; private set; }
private static long _cachedFrame = -1;
private static readonly Dictionary<int, float[]> CachedSpectrums = new Dictionary<int, float[]>();
private static readonly Dictionary<int, float[]> CachedSpectrums = new();
public static void Initialize(AudioClip? clip)
{
+1 -1
View File
@@ -128,7 +128,7 @@ namespace ADOFAIRenderer.Util.FFmpeg
private bool _disposed;
/// <summary>멀티스레딩 환경에서 인코더 상태 및 리소스 접근을 동기화하기 위한 락 객체.</summary>
private readonly object _lock = new object();
private readonly object _lock = new();
/// <summary>
/// QSV 인코더에서 hw_frames_ctx 모드(GPU 프레임 풀)가 활성화되었는지 여부.
+3 -3
View File
@@ -15,9 +15,9 @@ namespace ADOFAIRenderer.Util
{
private const int InitialBufferSize = 16;
private readonly Stack<ReadbackRequestState> _statePool = new Stack<ReadbackRequestState>();
private readonly List<ReadbackRequestState> _allocatedStates = new List<ReadbackRequestState>();
private readonly object _poolLock = new object();
private readonly Stack<ReadbackRequestState> _statePool = new();
private readonly List<ReadbackRequestState> _allocatedStates = new();
private readonly object _poolLock = new();
private bool _isInitialized;
private volatile bool _isDisposed;
+1 -1
View File
@@ -20,7 +20,7 @@ namespace ADOFAIRenderer.Util
private const string IntelPattern =
@"^Intel(?>\(R\))* (?>U*HD Graphics [0-9]+$|Arc\(TM\) [A-C][0-9]+ Graphics)";
private static readonly Dictionary<Codec, List<(GPUVendor, string)>> CodecMap = new Dictionary<Codec, List<(GPUVendor, string)>>
private static readonly Dictionary<Codec, List<(GPUVendor, string)>> CodecMap = new()
{
[Codec.H264] = new List<(GPUVendor, string)> { (GPUVendor.NVIDIA, "h264_nvenc"), (GPUVendor.Intel, "h264_qsv"), (GPUVendor.AMD, "h264_amf"), (GPUVendor.Unknown, "libx264") },
[Codec.H265] = new List<(GPUVendor, string)> { (GPUVendor.NVIDIA, "hevc_nvenc"), (GPUVendor.Intel, "hevc_qsv"), (GPUVendor.AMD, "hevc_amf"), (GPUVendor.Unknown, "libx265") },