(H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)

  • klotim
More
9 months 1 hour ago #301 by klotim Replied by klotim on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
github.com/mj-ehsan/NiceGuy-Shaders/blob/main/HoleFiller.fx
Will problably be a good mix with this shader:
"HoleFiller is made to assist AA shaders handle trees better. Fills harsh holes between tree leaves and vegetation. "

Please Log in or Create an account to join the conversation.

  • EFermi
More
8 months 4 weeks ago #302 by EFermi Replied by EFermi on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Found a most enjoyable article about antialiasing, dated 2019: www.overclockersclub.com/reviews/serious_statistics_aliasing/  

Maybe someone else would find it interesting.

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
8 months 4 weeks ago #303 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
I've changed over to a system where I'm pushing one update per calendar day (if I've done any work on the shader in that particular day). Over the last couple of days, I've made some improvements to dynamic thresholding and SMAA line detection as well as implemented full user control over spurious pixel detection and handling in the optional image softening. Performance should be expected to be slightly worse due to SMAA spending more time tracing out lines.

Please Log in or Create an account to join the conversation.

  • EFermi
More
8 months 3 weeks ago #304 by EFermi Replied by EFermi on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Today I learned SRAA is a thing, but it seems to not be ReShade-friendly. And I never even saw it in games.

research.nvidia.com/publication/2011-02_...ruction-antialiasing

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
8 months 3 weeks ago #305 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Looks like it was probably discarded in favor of Temporal AA, based on the publication date. The concept looks interesting but I don't think it's ReShade compatible as it appears to require the game to generate supersampled versions of both its depth and normal buffers.

Please Log in or Create an account to join the conversation.

  • Digika
More
7 months 3 weeks ago #306 by Digika Replied by Digika on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Yeah, seems like industry moves into AI memes territory with temporal pass. Gen5 TemporalAA inEU4.27 and 5 does wonders, bascially 0 jitter with super-sharp image but the cost ofit as heavy as the truck full of cows.

Please Log in or Create an account to join the conversation.

  • ssn650
More
7 months 2 weeks ago #307 by ssn650 Replied by ssn650 on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Hi lordbean
I'm really enjoying your HQAA solution for a DirectX 8 game I'm playing in CrossOver / Parallels Desktop on a MacBook Pro, where anti-aliasing isn't provided by the default graphics driver.
I have a question about the settings. I noted in the HQAA.fx file that there are a number of presets included, and since I'm using FakeHDR I added the following entry to my SweetFX_Settings configuration file:

[HQAA.fx]
HQAA__Global_Preset=7

Is this correcty formatted and do you have any recommendations / descriptions of the other presets that can be selected? Are there other parameters we can list under [HQAA.fx] in the configuration file to tweak the HQAA settings and see what differences they make?

Cheers
Geoffrey

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
7 months 1 week ago #308 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
I haven't personally used HQAA via SweetFX injection so I'm not familiar with the syntax it expects when parsing the file. Yes, there are a lot of user-configurable pre-processor defines - the best way to learn them would be to use it via a standard ReShade injection in a DirectX 9 or higher title since it will present them neatly to you when you expand the category.

Alternatively, if SweetFX offers an ingame configuration method similar to ReShade, you can pretty much duplicate the effect without using the global preset. The basic optional effects are enabled by default, and the one you want is under Color Palette. Enable that category, and pick Logarithmic Fake HDR from the tone mapper dropdown. The effective maximum strength for the parameter is euler's number, 2.718282 (approx). It will start to artifact if you go higher.

Please Log in or Create an account to join the conversation.

  • ssn650
More
7 months 1 week ago - 7 months 1 week ago #309 by ssn650 Replied by ssn650 on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Thank you!

I entered the Home screen during game play and noted that HQAA.fx was indeed selected and compiled.
After closing the game, the following entries were added to my SweetFX_Settings.txt file

[HQAA.fx]
HqaaAboutEOF=0
HQAAintroduction=0
HqaaOptionalsEOF=0
HqaaOptionsEOF=0

I've gone back to the default HQAA settings (without loading Preset No. 7 HDR) because I prefer them and since I've also loaded FakeHDR shaders probably don't need them anyway.

Cheers
Last edit: 7 months 1 week ago by ssn650.

Please Log in or Create an account to join the conversation.

  • TOGfan
More
7 months 1 week ago #310 by TOGfan Replied by TOGfan on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
I decided to play around with the temporal stabiliser mode and made some improvements that I think are worth sharing.
First I noticed that when using the temporal persistence mode together with clamp weight mode it created a significant amount of blurring because it used the previous frame with the stabilisation already applied and compared it with current frame without stabilisation. I changed it so that it uses only the previous frame without stabilisation.
I also added a treshold slider which completely disables blending if the weight falls below the treshold which limits blur and a frame limit slider which limits the weight of previous frame blending. I also implemented an adaptive temporal presistence mode which chooses between temporal persistance mode and normal mode per pixel based on which has the smaller difference to the current frame, which minimizes blur added by persistence mode.
If you like these changes lordbean, you can add them in the next update.
Warning: Spoiler!

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
7 months 1 week ago #311 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
The temporal stabilizer tends to rate low on my priority list of things to improve since I don't typically use it for everyday gaming personally - though I agree there are some parts of it that probably need improvement. The previous frame weight setting is a bit nebulous since it really only acts as a starting point and can be altered quite a bit by the other options on the fly.

Just for reference, disabling temporal persistence isn't the same thing as disabling previous-frame blending altogether. With temporal persistence disabled, HQAA will use the previous frame before stabilization as the reference to blend with the current frame, meaning stabilization changes do not persist to subsequent frames (hence "Temporal Persistence").

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
7 months 5 days ago #312 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
It's been a while since I mentioned an update here, so I'll do so now - although it's in LTS and likely largely final, I've continued to make small improvements to the shader over the last month or two that have gradually increased the quality of the output quite a bit. If you use it and haven't updated it in a while, you might want to consider doing so.

Please Log in or Create an account to join the conversation.

  • whamy03
More
7 months 3 days ago #313 by whamy03 Replied by whamy03 on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Hi! i'm new with these reshade thingy, i really love comparison images that you posted.. Any idea where i can get the repository for your reshade?

Please Log in or Create an account to join the conversation.

  • Kleio420
More
7 months 1 day ago #314 by Kleio420 Replied by Kleio420 on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
to say its never been used in games would be a hard one lot of games dont go out and tell you how their post aa/taa work and they may have been built around some of the concepts inside this. I think it is safe to assume nvidia likes to make aa algs to never use or do anything meaningful with them most likely due to better implimitations being made by lone devs. Txaa used in a hand full of games , temporal supersampling fxaa(fxaa 4.0) was never used and passed up for txaa and mfaa, then "DLAA" never got used till just recently even tho it was the original baseline of dlss their original rtx video shows dlaa off before dlss was ever announced.Nice thing is them doing all this gives public info on how they work for other devs to take inspiration from and keep making better methods, just like lordbean is doing playing around trying to improve how smaa/fxaa work honestly if its not been done yet you should rewrite a new file instead of using the original headers and optimize the code before going any further making a new framework to base future code off but hey my opinion.

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
7 months 22 hours ago - 7 months 21 hours ago #315 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
I actually merged the FXAA and SMAA headers into HQAA quite a while ago so that I could edit any part of the code I wanted to. My FXAA in particular works quite a bit differently than the original nvidia version at this point. I've changed SMAA some too, but not as much as FXAA.

@whamy03 - github.com/lordbean-git
Last edit: 7 months 21 hours ago by lordbean.

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
6 months 2 weeks ago #316 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
The core effect of HQAA (the anti-aliasing) is effectively complete at this point. Although I may revisit the optional effects over time, I believe I have reached the point where very little (if any) further improvement is possible. As far as I can tell, the anti-aliasing effect offered by HQAA (and its freshly-updated Lite edition) is more or less flawless. I am only aware of one specific edge pattern that HQAA does not always fully correct, and it is a pattern which SMAA has extreme difficulty with, and which FXAA is completely incapable of correcting.

Additionally, I have also added some of the fast optional effects in HQAA to QXAA (the stand-alone implementation of the FXAA shader used in HQAA). For those looking for a very good quality AA effect but without much GPU headroom, QXAA can offer a lot of improvement for relatively little input cost in GPU time, and can now also fill basic functions like sharpening, saturation, brightness, etc.
The following user(s) said Thank You: SpajdrEX

Please Log in or Create an account to join the conversation.

  • EFermi
More
5 months 1 day ago #317 by EFermi Replied by EFermi on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
With the last couple of versions I always get "division by zero" and/or NaN errors in DX9, here is an example from F.E.A.R.: 
[url] imgur.com/TDD3nHh [/url] 

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
5 months 23 hours ago #318 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
Just checked every API except Direct3D 10 on my PC, no problems compiling in any of them. (D3D9 - BorderlandsTPS / D3D11 - Snowrunner / Vulkan - Borderlands2 via DXVK, No Man's Sky / D3D12 - Satisfactory / OpenGL - Doom 3 BFG)

Please Log in or Create an account to join the conversation.

  • lordbean
  • Topic Author
More
4 months 2 weeks ago #319 by lordbean Replied by lordbean on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
HQAA v29.0 is now available, sporting a pretty significant improvement in the output quality compared to any v28.x revision. Although I haven't actually compared directly, it's also likely a bit faster, especially if you haven't updated in a while.

Please Log in or Create an account to join the conversation.

  • Kleio420
More
4 months 2 weeks ago #320 by Kleio420 Replied by Kleio420 on topic (H)ybrid high-(Q)uality (A)nti-(A)liasing (HQAA)
any chance you could look into a compile error with open gl game in specific is the sims 4 think its open gl off hand , i was wanting to look at your shader since its been several months from the last time i played with it.

Please Log in or Create an account to join the conversation.

We use cookies

We use cookies on our website. Some of them are essential for the operation of the site, while others help us to improve this site and the user experience (tracking cookies). You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.