Added check to avoid disposing of default device

このコミットが含まれているのは:
Sergio Pedri committed 2020-11-21 21:53:05 +01:00
1 親 aa55ac5043
コミット c2a1980596
3ファイル変更
+18 -1

検索条件に一致するファイルはありません

+1 -1
ファイルの表示
@@ -13,7 +13,7 @@ namespace ComputeSharp.Graphics
/// <param name="description">The available info for the associate device.</param>
internal unsafe GraphicsDeviceInfo(DXGI_ADAPTER_DESC1* dxgiDescription1)
{
Luid = *(Luid*)&dxgiDescription1->AdapterLuid;
Luid = Luid.FromLUID(dxgiDescription1->AdapterLuid);
Name = new string((char*)dxgiDescription1->Description);
MemorySize = dxgiDescription1->DedicatedVideoMemory;
}