Align managed raster RenderGraph authoring with URP

This commit is contained in:
2026-04-26 23:32:09 +08:00
parent 09b1289338
commit 3b38d65ab8
13 changed files with 430 additions and 123 deletions

View File

@@ -46,12 +46,24 @@ namespace ProjectScripts
ScriptableRenderContext context,
RenderingData renderingData)
{
return context != null &&
renderingData != null &&
renderingData.isPostProcessStage &&
RecordColorScaleFullscreenPass(
context,
new Vector4(1.15f, 0.95f, 1.05f, 1.0f));
if (context == null ||
renderingData == null ||
!renderingData.isPostProcessStage ||
!context.sourceColorTexture.isValid ||
!context.primaryColorTarget.isValid)
{
return false;
}
return context
.AddRasterPass("Project.PostProcessColorScale")
.UseColorSource(context.sourceColorTexture)
.SetColorAttachment(context.primaryColorTarget)
.SetRenderFunc(
rasterContext =>
{
})
.Commit();
}
}