Add URP RenderGraph API compatibility surface
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
using System.Reflection;
|
||||
using XCEngine;
|
||||
using XCEngine.Rendering;
|
||||
using XCEngine.Rendering.RenderGraphModule;
|
||||
using XCEngine.Rendering.Universal;
|
||||
|
||||
namespace Gameplay
|
||||
@@ -98,6 +99,12 @@ namespace Gameplay
|
||||
public bool HasRenderPassOnCameraSetup;
|
||||
public bool HasRenderPassOnCameraCleanup;
|
||||
public bool HasRenderPassOnFinishCameraStackRendering;
|
||||
public bool HasContextItemType;
|
||||
public bool HasContextContainerType;
|
||||
public bool HasContextContainerGetOrCreate;
|
||||
public bool HasRenderGraphType;
|
||||
public bool HasRenderGraphAddRasterPass;
|
||||
public bool HasRenderPassPublicRecordRenderGraph;
|
||||
public bool HasRenderPassComparisonOperators;
|
||||
public bool HasRenderPassEventUnityNumericOrder;
|
||||
public bool HasRenderPassEventEngineExtensionOrder;
|
||||
@@ -129,6 +136,12 @@ namespace Gameplay
|
||||
typeof(CommandBuffer);
|
||||
System.Type profilingSamplerType =
|
||||
typeof(ProfilingSampler);
|
||||
System.Type contextItemType =
|
||||
typeof(ContextItem);
|
||||
System.Type contextContainerType =
|
||||
typeof(ContextContainer);
|
||||
System.Type renderGraphType =
|
||||
typeof(RenderGraph);
|
||||
System.Type renderPassInputType =
|
||||
typeof(ScriptableRenderPassInput);
|
||||
System.Type universalAssemblyType =
|
||||
@@ -541,6 +554,39 @@ namespace Gameplay
|
||||
typeof(CommandBuffer)
|
||||
},
|
||||
null) != null;
|
||||
HasContextItemType =
|
||||
contextItemType != null;
|
||||
HasContextContainerType =
|
||||
contextContainerType != null &&
|
||||
typeof(System.IDisposable).IsAssignableFrom(
|
||||
contextContainerType);
|
||||
HasContextContainerGetOrCreate =
|
||||
contextContainerType.GetMethod(
|
||||
"GetOrCreate",
|
||||
PublicInstanceMethodFlags) != null;
|
||||
HasRenderGraphType =
|
||||
renderGraphType != null;
|
||||
HasRenderGraphAddRasterPass =
|
||||
renderGraphType.GetMethod(
|
||||
"AddRasterPass",
|
||||
PublicInstanceMethodFlags,
|
||||
null,
|
||||
new System.Type[]
|
||||
{
|
||||
typeof(string)
|
||||
},
|
||||
null) != null;
|
||||
HasRenderPassPublicRecordRenderGraph =
|
||||
renderPassType.GetMethod(
|
||||
"RecordRenderGraph",
|
||||
PublicInstanceMethodFlags,
|
||||
null,
|
||||
new System.Type[]
|
||||
{
|
||||
typeof(RenderGraph),
|
||||
typeof(ContextContainer)
|
||||
},
|
||||
null) != null;
|
||||
HasRenderPassComparisonOperators =
|
||||
renderPassType.GetMethod(
|
||||
"op_GreaterThan",
|
||||
|
||||
Reference in New Issue
Block a user