[new] ATOM-17253 Using AtomTressFX gem as an example to inject hair passes to main pipeline at run-time (#7661)
* Change AtomTressFX passes to write to exsiting DepthLinear buffer instead of creating a new one as output. Signed-off-by: Qing Tao <55564570+VickyAtAZ@users.noreply.github.com> * Added new api in RPI to apply render pipeline changes from FP Signed-off-by: Qing Tao <55564570+VickyAtAZ@users.noreply.github.com> * Update AtomTressFX gem to create hair parent pass at runtime Signed-off-by: Qing Tao <55564570+VickyAtAZ@users.noreply.github.com> * Change Scene::ApplyRenderPipelineChange() to TryApplyRenderPIpelineChanges(). Have TryApplyRenderPIpelineChanges() called automatically when a render pipeline is added to a Scene. Re-apply the render pipeline change when RenderPipeline got recreated (Pass hot-reloading support) Add AddPassBefore() and AddPassAfter() function to RenderPIpeline class. Signed-off-by: Qing Tao <55564570+VickyAtAZ@users.noreply.github.com>
This commit is contained in:
@@ -215,99 +215,6 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
{
|
||||
// NOTE: HairParentPass does not write into Depth MSAA from Opaque Pass. If new passes downstream
|
||||
// of HairParentPass will need to use Depth MSAA, HairParentPass will need to be updated to use Depth MSAA
|
||||
// instead of regular Depth as DepthStencil. Specifically, HairResolvePPLL.pass and the associated
|
||||
// .azsl file will need to be updated.
|
||||
"Name": "HairParentPass",
|
||||
// Note: The following two lines represent the choice of rendering pipeline for the hair.
|
||||
// You can either choose to use PPLL or ShortCut and accordingly change the flag
|
||||
// 'm_usePPLLRenderTechnique' in the class 'HairFeatureProcessor.cpp'
|
||||
// "TemplateName": "HairParentPassTemplate",
|
||||
"TemplateName": "HairParentShortCutPassTemplate",
|
||||
"Enabled": true,
|
||||
"Connections": [
|
||||
// Critical to keep DepthLinear as input - used to set the size of the Head PPLL image buffer.
|
||||
// If DepthLinear is not available - connect to another viewport (non MSAA) image.
|
||||
{
|
||||
"LocalSlot": "DepthLinearInput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "DepthLinear"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "Depth",
|
||||
"AttachmentRef": {
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "RenderTargetInputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "OpaquePass",
|
||||
"Attachment": "Output"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "RenderTargetInputOnly",
|
||||
"AttachmentRef": {
|
||||
"Pass": "OpaquePass",
|
||||
"Attachment": "Output"
|
||||
}
|
||||
},
|
||||
|
||||
// Shadows resources
|
||||
{
|
||||
"LocalSlot": "DirectionalShadowmap",
|
||||
"AttachmentRef": {
|
||||
"Pass": "ShadowPass",
|
||||
"Attachment": "DirectionalShadowmap"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "DirectionalESM",
|
||||
"AttachmentRef": {
|
||||
"Pass": "ShadowPass",
|
||||
"Attachment": "DirectionalESM"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "ProjectedShadowmap",
|
||||
"AttachmentRef": {
|
||||
"Pass": "ShadowPass",
|
||||
"Attachment": "ProjectedShadowmap"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "ProjectedESM",
|
||||
"AttachmentRef": {
|
||||
"Pass": "ShadowPass",
|
||||
"Attachment": "ProjectedESM"
|
||||
}
|
||||
},
|
||||
|
||||
// Lighting Resources
|
||||
{
|
||||
"LocalSlot": "TileLightData",
|
||||
"AttachmentRef": {
|
||||
"Pass": "LightCullingPass",
|
||||
"Attachment": "TileLightData"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "LightListRemapped",
|
||||
"AttachmentRef": {
|
||||
"Pass": "LightCullingPass",
|
||||
"Attachment": "LightListRemapped"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
{
|
||||
"Name": "TransparentPass",
|
||||
"TemplateName": "TransparentParentTemplate",
|
||||
@@ -357,22 +264,22 @@
|
||||
{
|
||||
"LocalSlot": "InputLinearDepth",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "DepthLinear"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "DepthStencil",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "InputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Attachment": "RenderTargetInputOutput"
|
||||
"Pass": "OpaquePass",
|
||||
"Attachment": "Output"
|
||||
}
|
||||
}
|
||||
]
|
||||
@@ -385,22 +292,22 @@
|
||||
{
|
||||
"LocalSlot": "InputLinearDepth",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "DepthLinear"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "InputDepthStencil",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "RenderTargetInputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Attachment": "RenderTargetInputOutput"
|
||||
"Pass": "TransparentPass",
|
||||
"Attachment": "InputOutput"
|
||||
}
|
||||
}
|
||||
],
|
||||
@@ -440,7 +347,7 @@
|
||||
{
|
||||
"LocalSlot": "Depth",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
},
|
||||
@@ -502,7 +409,7 @@
|
||||
{
|
||||
"LocalSlot": "DepthInputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
}
|
||||
@@ -561,7 +468,7 @@
|
||||
{
|
||||
"LocalSlot": "DepthInputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
}
|
||||
@@ -574,14 +481,14 @@
|
||||
{
|
||||
"LocalSlot": "InputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "LyShinePass",
|
||||
"Attachment": "ColorInputOutput"
|
||||
"Pass": "DebugOverlayPass",
|
||||
"Attachment": "InputOutput"
|
||||
}
|
||||
},
|
||||
{
|
||||
"LocalSlot": "DepthInputOutput",
|
||||
"AttachmentRef": {
|
||||
"Pass": "HairParentPass",
|
||||
"Pass": "DepthPrePass",
|
||||
"Attachment": "Depth"
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user