AcademySoftwareFoundation / MaterialX

MaterialX is an open standard for the exchange of rich material and look-development content across applications and renderers.
http://www.materialx.org/
Apache License 2.0
1.83k stars 335 forks source link

Add temporal antialiasing to MaterialX Viewer #1723

Open jstone-lucasfilm opened 6 months ago

jstone-lucasfilm commented 6 months ago

The MaterialX Viewer might benefit from a simple implementation of temporal antialiasing, where the camera transform is jittered each frame, and successive frames are blended together.

In the context of the MaterialX Viewer, no dynamic reprojection would need to be used, and the history buffer could simply be cleared when the user moves the camera.

This antialiasing technique might work particularly well in addressing aliasing of under-sampled MaterialX patterns, which commonly appear in comparisons between real-time and offline renders, and could additionally improve the effectiveness of Filtered Importance Sampling in the context of the viewer.

The following are a few resources that may be useful in this implementation:

meshula commented 1 month ago

Miscellaneous note regarding an inexpensive implementation from the Playstation 2 era, as used in AAA games:

The camera was jittered according to a Poisson distribution where the size of the distribution was such that 50% of the samples fell within the computed circle of confusion at the focus distance. This technique therefore gives depth of field efects as well. The amount of bias towards new samples was scaled with the derivative of the camera motion, so that rapid motion would rapidly wipe out the accumulation, and if the camera was barely moving the accumulation was greater.