You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
o3de/Gems/Atom/Feature/Common/Assets/Shaders/PostProcessing
Ken Pruiksma 9df995dd26
Temporal anti-aliasing and constrast adaptive sharpening (#1161)
First version of temporal antialiasing and contrast adaptive sharpening for GA. Works well in most cases but still has a few issues that will need additional time. This is only the passes and shaders with no exposure to the editor. TAA and CAS can be turned on by enabling their respective passes in the pipeline.

All of the code has been previously reviewed in smaller PRs into the taa_staging branch:
aws-lumberyard-dev#29
aws-lumberyard-dev#53
aws-lumberyard-dev#73
aws-lumberyard-dev#79
aws-lumberyard-dev#84

Main issues:

- Bloom doesn't play nice with TAA and seems to greatly amplify any flickering
- AuxGeom jitters with the camera, so TAA doesn't currently work well in editor
- Transparencies don't have correct motion vectors. History rectification keeps this from looking too bad, but could still be improved
- There is still more that could be done to inhibit flickering, usually from specular aliasing
- Motion vectors aren't correct on POM unless PDO is turned on, which can result in some blurring during motion.
- SSAO can contribute to flickering in its default half res configuration. Changing this to full res mitigates the problem.

Squashed merge of the following:

* [ATOM-13987] Initial checkin of Taa pass.

* TAA pass setup WIP. (does not work yet due to pass configuration issues).

* Taa WIP - Camera motion vectors fixed and hooked up. TAA does simple reprojection and rejection based on depth.

* Small update to use lerp and add some comments.

* Fix issue with attachments not being set up on bindings at initialization. Fixing issue with half-pixel offsets in TAA shader

* - Motion vector passes now use the same output with mesh motion vectors overwriting camera motion vectors.
- Taa pass now works with multiple pipelines.
- Cleaned up TAA shader a bit.

* Fixes from PR review.

* Adding check for multiple attachments of the same name with different resources in Pass::ImportAttachments().

* Adding camera jitter with configurable position count. Updated TAA to blend in tonemapped space.

* Fixes from PR review. Fixing camera motion vectors for background (infinite distance)

* Updates to taa shader from PR review

* Adding a rcp input color size.

* Fix comment on PassAttachment::Update()

* Updates for PR review.

* Fixing missing const on the FrameAttachment* in Pass's call to FindAttachment()

* Taa WIP - Adding filtering to both the current pixel and history. Adding rectification based on variance clipping. Adding some basic anti-flickering. Removing rejection based on depth.

* Updates from PR code review. Mostly better commenting and naming.

* Adding contrast adaptive sharpening based on AMD FidelityFX CAS to help with the softness added by TAA.

* Changing to using luminance for sharpening instead of just green. Added some comments.

* Moving Taa's NaN check to a better location. Disabling TAA and sharpening in prep for check in.

* Updates from PR feedback.
5 years ago
..
AcesOutputTransformLut.azsl Add newlines to the end of all files 5 years ago
AcesOutputTransformLut.shader Integrating github/staging through commit b0dd7ed 5 years ago
ApplyShaperLookupTable.azsl Add newlines to the end of all files 5 years ago
ApplyShaperLookupTable.shader Integrating github/staging through commit b0dd7ed 5 years ago
BakeAcesOutputTransformLutCS.azsl Add newlines to the end of all files 5 years ago
BakeAcesOutputTransformLutCS.shader Add newlines to the end of all files 5 years ago
BlendColorGradingLuts.azsl Add newlines to the end of all files 5 years ago
BlendColorGradingLuts.shader Add newlines to the end of all files 5 years ago
BlendColorGradingLuts.shadervariantlist Initial commit 5 years ago
BloomBlurCS.azsl Initial commit 5 years ago
BloomBlurCS.shader Add newlines to the end of all files 5 years ago
BloomCompositeCS.azsl Initial commit 5 years ago
BloomCompositeCS.shader Add newlines to the end of all files 5 years ago
BloomDownsampleCS.azsl Initial commit 5 years ago
BloomDownsampleCS.shader Add newlines to the end of all files 5 years ago
ContrastAdaptiveSharpening.azsl Temporal anti-aliasing and constrast adaptive sharpening (#1161) 5 years ago
ContrastAdaptiveSharpening.shader Temporal anti-aliasing and constrast adaptive sharpening (#1161) 5 years ago
ConvertToAcescg.azsl Add newlines to the end of all files 5 years ago
ConvertToAcescg.shader Initial commit 5 years ago
DepthDownsample.azsl Initial commit 5 years ago
DepthDownsample.shader Initial commit 5 years ago
DepthOfField.azsli Initial commit 5 years ago
DepthOfFieldBlurBokeh.azsl Removed unneeded comments (#673) 5 years ago
DepthOfFieldBlurBokeh.shader Initial commit 5 years ago
DepthOfFieldBlurBokeh.shadervariantlist Initial commit 5 years ago
DepthOfFieldComposite.azsl Removed unneeded comments (#673) 5 years ago
DepthOfFieldComposite.shader Initial commit 5 years ago
DepthOfFieldComposite.shadervariantlist Initial commit 5 years ago
DepthOfFieldDownSample.azsl Initial commit 5 years ago
DepthOfFieldDownSample.shader Initial commit 5 years ago
DepthOfFieldMask.azsl Initial commit 5 years ago
DepthOfFieldMask.shader Initial commit 5 years ago
DepthOfFieldPrepare.azsl Initial commit 5 years ago
DepthOfFieldPrepare.shader Initial commit 5 years ago
DepthOfFieldWriteFocusDepthFromGpu.azsl Initial commit 5 years ago
DepthOfFieldWriteFocusDepthFromGpu.shader Initial commit 5 years ago
DepthToLinearDepth.azsl Add newlines to the end of all files 5 years ago
DepthToLinearDepth.shader Initial commit 5 years ago
DepthUpsample.azsl Initial commit 5 years ago
DepthUpsample.shader Initial commit 5 years ago
DiffuseSpecularMerge.azsl Add newlines to the end of all files 5 years ago
DiffuseSpecularMerge.shader Initial commit 5 years ago
DisplayMapper.azsl Add newlines to the end of all files 5 years ago
DisplayMapper.shader Initial commit 5 years ago
DisplayMapperOnlyGammaCorrection.azsl Add newlines to the end of all files 5 years ago
DisplayMapperOnlyGammaCorrection.shader Initial commit 5 years ago
DownsampleLuminanceMinAvgMaxCS.azsl Add newlines to the end of all files 5 years ago
DownsampleLuminanceMinAvgMaxCS.shader Add newlines to the end of all files 5 years ago
DownsampleMinAvgMaxCS.azsl Add newlines to the end of all files 5 years ago
DownsampleMinAvgMaxCS.shader Add newlines to the end of all files 5 years ago
EyeAdaptation.azsl Add newlines to the end of all files 5 years ago
EyeAdaptation.shader Add newlines to the end of all files 5 years ago
EyeAdaptationUtil.azsli Initial commit 5 years ago
FastDepthAwareBlurCommon.azsli Initial commit 5 years ago
FastDepthAwareBlurHor.azsl Initial commit 5 years ago
FastDepthAwareBlurHor.shader Initial commit 5 years ago
FastDepthAwareBlurVer.azsl Initial commit 5 years ago
FastDepthAwareBlurVer.shader Initial commit 5 years ago
FullscreenCopy.azsl Add newlines to the end of all files 5 years ago
FullscreenCopy.shader Initial commit 5 years ago
LookModificationTransform.azsl Add newlines to the end of all files 5 years ago
LookModificationTransform.shader Initial commit 5 years ago
LookModificationTransform.shadervariantlist Initial commit 5 years ago
LuminanceHeatmap.azsl Add newlines to the end of all files 5 years ago
LuminanceHeatmap.shader Initial commit 5 years ago
LuminanceHistogramCommon.azsli Initial commit 5 years ago
LuminanceHistogramGenerator.azsl Initial commit 5 years ago
LuminanceHistogramGenerator.shader Disable metal shaders that dont cross compile correctly 5 years ago
MSAAResolveCustom.azsl Add newlines to the end of all files 5 years ago
MSAAResolveCustom.shader Add newlines to the end of all files 5 years ago
MSAAResolveDepth.azsl Add newlines to the end of all files 5 years ago
MSAAResolveDepth.shader Initial commit 5 years ago
ModulateTexture.azsl Initial commit 5 years ago
ModulateTexture.shader Initial commit 5 years ago
OutputTransform.azsl Add newlines to the end of all files 5 years ago
OutputTransform.shader Initial commit 5 years ago
OutputTransform.shadervariantlist Initial commit 5 years ago
SMAA.azsli Integrating latest 47acbe8 5 years ago
SMAABlendingWeightCalculation.azsl Add newlines to the end of all files 5 years ago
SMAABlendingWeightCalculation.shader Initial commit 5 years ago
SMAAConvertToPerceptualColor.azsl Add newlines to the end of all files 5 years ago
SMAAConvertToPerceptualColor.shader Initial commit 5 years ago
SMAAEdgeDetection.azsl Add newlines to the end of all files 5 years ago
SMAAEdgeDetection.shader Initial commit 5 years ago
SMAANeighborhoodBlending.azsl Initial commit 5 years ago
SMAANeighborhoodBlending.shader Initial commit 5 years ago
SMAAUtils.azsli Initial commit 5 years ago
ScreenSpaceSubsurfaceScatteringCS.azsl Initial commit 5 years ago
ScreenSpaceSubsurfaceScatteringCS.shader Add newlines to the end of all files 5 years ago
SsaoCompute.azsl ATOM-15391 [RHI][Vulkan][Android] SSAO introduces horizontal lines on flat surfaces 5 years ago
SsaoCompute.shader Initial commit 5 years ago
Taa.azsl Temporal anti-aliasing and constrast adaptive sharpening (#1161) 5 years ago
Taa.shader Temporal anti-aliasing and constrast adaptive sharpening (#1161) 5 years ago
UniformColor.azsl Initial commit 5 years ago
UniformColor.shader Initial commit 5 years ago