Refactor rendering projects

This commit is contained in:
2026-02-24 20:08:26 +09:00
parent 93c58fa7fb
commit 30090f84ab
88 changed files with 1350 additions and 1136 deletions

View File

@@ -32,13 +32,22 @@ public partial class UnitTestApp : Application
OperatingSystem.IsMacOS() ? "osx" : "unknown";
var arch = Environment.Is64BitProcess ? "x64" : "x86";
var nativeDllDir = Path.Combine(currentDir, "runtimes", platform + "-" + arch, "native");
if (Directory.Exists(nativeDllDir))
//if (Directory.Exists(nativeDllDir))
//{
// foreach (var dll in Directory.EnumerateFiles(nativeDllDir, "*.dll"))
// {
// NativeLibrary.Load(dll);
// }
//}
NativeLibrary.SetDllImportResolver(typeof(UnitTestApp).Assembly, (libraryName, assembly, searchPath) =>
{
foreach (var dll in Directory.EnumerateFiles(nativeDllDir, "*.dll"))
if (libraryName == "dxcompiler")
{
NativeLibrary.Load(dll);
NativeLibrary.Load(Path.Combine(nativeDllDir, "dxil.dll"));
}
}
return IntPtr.Zero;
});
}
/// <summary>

View File

@@ -6,6 +6,7 @@
<ImplicitUsings>enable</ImplicitUsings>
<Nullable>enable</Nullable>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<PublishAot>True</PublishAot>
</PropertyGroup>
<ItemGroup>