Add managed render pipeline selection bridge

This commit is contained in:
2026-04-15 01:57:14 +08:00
parent ec6965b0dd
commit aa727202af
18 changed files with 566 additions and 10 deletions

View File

@@ -0,0 +1,34 @@
using System;
namespace XCEngine
{
public static class GraphicsSettings
{
public static Type renderPipelineAssetType
{
get
{
string assemblyQualifiedName =
InternalCalls.Rendering_GetRenderPipelineAssetTypeName();
if (string.IsNullOrEmpty(assemblyQualifiedName))
{
return null;
}
return Type.GetType(assemblyQualifiedName, throwOnError: false);
}
set
{
if (value != null &&
!typeof(RenderPipelineAsset).IsAssignableFrom(value))
{
throw new ArgumentException(
"GraphicsSettings.renderPipelineAssetType must derive from RenderPipelineAsset.",
nameof(value));
}
InternalCalls.Rendering_SetRenderPipelineAssetType(value);
}
}
}
}