Antialiasing

This feature was added as an optional pass to counter artifacts that may come with using temporal based anti-aliasing like TAA, TSR and Nvidia/AMD/Intel's own versions. It uses a morphological AA method called CMAA2arrow-up-right. It's worth noting that as of UE 5.7, Epic has added SMAA to the engine.

The antialiasing setup has been streamlined compared to the previous version and is much easier to set up. Here is how:

1

Settings

Set the Anti Alias Method to CMAA2 and adjust the Pass Location to your chosen location, for ease you can set it to Pre Post Process.

2

Material Input

Create a new material, this material is what will get rendered before the antialiasing is applied. It is also the material that you will set the Outline Material value to.

In your material, make sure the material domainarrow-up-right is set to Post Process.

Create your outline and output the colour along with an alpha mask to the Antialias Input node. You can also output to the emissive to see a preview, however it won't be used. The material can look something like below, which is for a simple outline.

  • Green is the render target asset that the simple outline/distance field outputs to.

  • Orange is the mask that will be colourised and used for the alpha channel.

  • Purple is the colourising of the mask.

  • Blue is the output that will be used as the input for the antialiasing.

3

Material Output

If your Pass Location value is set to any of the following:

  • Pre Post Process

  • Motion Blur

  • Tonemapping

Your result will be automatically render to the scene colour texture. However, if you do not want this you can set it to Render Target and either access the result in the materials directly as it is saved in your assigned asset path or use the dedicated Antialias Output node and use it in a normal Post Process materialarrow-up-right.

Last updated