Refactor namespaces and improve resource handling

- Updated namespaces from `Ghost.UnitTest` to `Ghost.Graphics.Test` across multiple files.
- Refactored `GraphicsTestWindow` to use a new `RenderSystem` configuration.
- Removed deprecated `Logger` and `SerializationTest` classes.
- Improved memory management in D3D12 components, including resource allocation and cleanup.
- Added `[SupportedOSPlatform]` attributes to specify Windows version compatibility.
- Updated `.editorconfig` settings and project references for consistency.
- Enabled `nativeDebugging` in `launchSettings.json`.
This commit is contained in:
2025-11-11 21:30:47 +09:00
parent fb003da26a
commit 6f786a0698
35 changed files with 334 additions and 401 deletions

View File

@@ -6,9 +6,13 @@ using TerraFX.Interop.Windows;
namespace Ghost.Core.Utilities;
#if PLATEFORME_WIN64
[SupportedOSPlatform("windows10.0.19041.0")]
internal static unsafe class Win32Utility
internal static partial class Win32Utility
{
public const string OS_SUPPORTED_VERSION = "windows10.0.19041.0";
}
[SupportedOSPlatform(OS_SUPPORTED_VERSION)]
internal static unsafe partial class Win32Utility
{
[EditorBrowsable(EditorBrowsableState.Never)]
public readonly ref struct IID_PPV
@@ -70,14 +74,21 @@ internal static unsafe class Win32Utility
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static void** PPV<T>(this ComPtr<T> comPtr)
public static Guid* IID<T>(this T ptr)
where T : unmanaged, IUnknown.Interface
{
return Windows.__uuidof<T>();
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static void** PPV<T>(ref this ComPtr<T> comPtr)
where T : unmanaged, IUnknown.Interface
{
return (void**)comPtr.GetAddressOf();
}
[MethodImpl(MethodImplOptions.AggressiveInlining)]
public static void** ReleaseAndGetVoidAddressOf<T>(this ComPtr<T> comPtr)
public static void** ReleaseAndGetVoidAddressOf<T>(ref this ComPtr<T> comPtr)
where T : unmanaged, IUnknown.Interface
{
return (void**)comPtr.ReleaseAndGetAddressOf();
@@ -98,5 +109,4 @@ internal static unsafe class Win32Utility
{
return (flags & Unsafe.As<T, uint>(ref flag)) != 0;
}
}
#endif
}