What is the best anti aliasing setting in games and how does it work in Unity?
The best Anti-Aliasing setting:
The choice of 'best' Anti-Aliasing (AA) depends largely on the requirement and resource capacity of the game. Some popular AA techniques include MSAA (Multi-Sample Anti-Aliasing), FXAA (Fast Approximate Anti-Aliasing), SMAA (Subpixel Morphological Anti-Aliasing), and TAA (Temporal Anti-Aliasing). TAA provides the best blend of visual result and performance among these.
Anti-Aliasing in Unity:
Unity provides built-in support for some Anti-Aliasing techniques, including MSAA and a variant of TAA referred to as 'Cinematic Anti-Aliasing'. Unity's Post-Processing Stack also allows the use of FXAA and TAA.
Implementation of AA in Unity:
For enabling MSAA:
QualitySettings.antiAliasing = 2; //Possible values: 0, 2, 4, 8. For enabling TAA or FXAA, you can add a Post-Process Layer to your camera and then add a Post-Process Volume to your scene with AA as one of the effects.