How to make Temporal AA (Antialiasing) stop flickering / Jittering / Moving ? [GIF included]

This is something that has been bothering me for as long as I’ve used the engine now and I have searched high and low for a way of improving/fixing it for years & have tried many things including forward rendering etc, but I still have not found a good solution that fixes it. How do I use Temporal AA(Antialiasing) without it flickering/moving around the screen even when nothing in the scene is even moving including the character? And if there is truly no way to do this, why would anyone even want to use Temporal AA in the first place? And if there is no way to do this, then how do I stop all the jagged movement when using FXAA instead of Temporal AA? The jagged movement is so bad for my specific project that no solution seems to be available. Temporal AA is great for my project when the character is moving, and FXAA is great for my project when the character is not moving, it would be nice to somehow turn on FXAA when a player’s character is not moving and turn on Temporal AA when a player’s character is moving.

Edit:
Unfortunately, the post processing effect is not the cause of this. I’ve recorded an example of the problem which I uploaded to an image host as a gif. This problem happens on any level, in any engine version, with any lighting applied, on any operating system, without any post processing effects applied. This is when Temporal AA is turned on. You’ll see I tried to “circle” the areas with the cursor where it can be seen flickering. Nothing is supposed to be moving in this scene except for the mouse cursor, nor is the camera moving. I’ve been baffled as to why this is happening for a long time, but I’m sure someone will know once they see it. Here’s the link to it as I’m not able to upload it on here unfortunately. https://s8.gifyu.com/images/TemporalAA.gif

Edit 2:
Here is a Brand New Unedited Project, using the First Person Template map in 4.25.4, in which I’ve only placed a few pieces from the starter content to showcase that this is happening no matter what project/content I use (I haven’t imported any content into this project or changed any project settings), again I’ve circled the areas with the mouse cursor if they weren’t obvious enough. https://s8.gifyu.com/images/TemporalAADefault.gif

No idea what you’re talking about tbh

What you’re describing doesn’t sound like TAA, certainly not anything I have ever experienced

It’s most likely related to the low-resolution effect of the project. Anti-aliasing, in general, averages the pixel coverage of edges to generate a smoother-looking result. At edges it is particularly noticeable due to a number of factors, one of which is the color / depth difference between the edge(s) and surrounding pixels (such as other objects in the scene at different depths and having different colors / shading). I suggest you do research about it to understand it better and see if there’s a way to optimize the low-resolution effect so it’s not so bad or problematic. Blurring isn’t a viable option because it’ll probably damage the effect of low-resolution, and it makes things look blurred or lower quality that are not intended to be. Look up the method for producing MSAA, which is often shown to be of higher quality in anti-aliasing, and see if there’s one or a few ways to emulate it in the engine. The other problem is resolution, which is affected by screen percentage, and there’s a few cvars accessible in the console or .ini files to alter aliasing (jaggedness / pixelation) so it’s not so strong or noticeable. This has the effect, though, of increasing resolution and may disrupt the low-res effect you’re trying for.

Unfortunately, the post processing effect is not the cause of this. I’ve recorded an example of the problem which I uploaded to an image host as a gif. This problem happens on any level, in any engine version, with any lighting applied, on any operating system, without any post processing effects applied. This is when Temporal AA is turned on. You’ll see I tried to “circle” the areas with the cursor where it can be seen flickering. Nothing is supposed to be moving in this scene except for the mouse cursor, nor is the camera moving. I’ve been baffled as to why this is happening for a long time, but I’m sure someone will know once they see it. Here’s the link to it as I’m not able to upload it on here unfortunately. No post processing applied, nothing should be moving except the mouse cursor: https://s8.gifyu.com/images/TemporalAA.gif

Yeah that’s probably TAA. This seems like an extreme case, I suspect this is a result of how you authored your content. Perhaps too many thin surfaces resolving to a single pixel, not sure.

I’m not sure what you mean by a result of how I authored my content? This is happening on any content, whether my own, marketplace, or Epic’s which is another reason I’m confused as to what is going on. The gif I recorded is of content of a demo scene from the marketplace. On 4.25.4.

Here is a Brand New Unedited Project, using the First Person Template map in 4.25.4, in which I’ve only placed a few pieces from the starter content to showcase that this is happening no matter what project/content I use (I haven’t imported any content into this project or changed any project settings), again I’ve circled the areas with the mouse cursor if they weren’t obvious enough. https://s8.gifyu.com/images/TemporalAADefault.gif

I gave my best guess in my post already: Thin surfaces that are resolving to less than a pixel. I figure you can probably fix this for some objects simply by making the LODs chunkier. Others are more difficult such as surfaces at glancing angles.

Are you rendering at reduced screen percentage? Because thats the only way I was able to make this issue obvious enough to be noticeable.

You could try changing the values in the TAA commands: r.TemporalAA*

It’s still happening even when testing as play new editor window fullscreen, I also tried standalone fullscreen(no borders) and it’s also happening there as well. I will take a look at the TAA commands.

Thank you Arkiras for suggesting to try the temporal commands, I tried lowering the samples by using r.TemporalAASamples 1, and it seems to fix the problem and I no longer notice any jittering/flickering, even when the resolution is lowered it seems fine now as well, so does anyone know why that would be? Im still a bit confused about TemporalAA. So even if its fixed I’d like to understand better what went wrong.

I’m so happy right now as I was dealing with this for so many years, I thought that I would have to settle on FXAA with its jaggedness.

3 Likes

Might want to try reducing r.TemporalAACurrentFrameWeight to something lower, like 0.01 maybe. Instead of reducing the sample count, as fewer samples reduces the antialiasing effect.

Unfortunately reducing the Samples to 1 was the only thing that fixed it, I also have the frameweight set to 0. With these settings its a MAJOR improvement over FXAA.

Hello,

****** HERE’S FLICKERING FIX *********************

Official 4.25 and 4.26 having some glitches in calculations, namely TemporalAAHistory structure was not filled out correctly

Here’s the only solution that will surely fix for both 4.25 and 4.26 versions (building from the source and fixing engine glitch), since 4.25 will not have any more updates and 4.26 also has the same issue:

  1. get Unreal 4.25 source, following link is a step by step instructions on how to get the source (no need for the building until you change buggy scripts, just when you get 4.25 source unzipped from git, run Setup.bat, after that **run GenerateProjectFiles.bat **): https://www.youtube.com/watch?v=dZck7_4vlYI&feature=emb_title&ab_channel=MichaelAllar

  2. **change this 2 scripts **as explained in the below link, and finally, **build the source **
    https://github.com/EpicGames/UnrealE…48f5a38dfb53ea

  3. compile your project from source (in the following link, instructions are around 8.50 min): https://www.youtube.com/watch?v=dZck7_4vlYI&feature=emb_title&ab_channel=MichaelAllar


Enjoy again your UE4.25/26

Cheers,
Mike

Have the same problem in UE 4.27.2. Do you know how to fix it without any project rebuilding?

1 Like

The second link is dead. What scripts? What fixes?

What helped me in 4.27 is to set Bloom in postprocess to 0.