Welcome, Guest.
Username: Password: Remember me

TOPIC: Marty McFly's Ambient Obscurance (MXAO) with IL

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #81

I'm glad you changed the IL blend. IL will look much more realistic now, but I'll have to try this out when I get home
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #82

Marty McFly wrote:
I did various changes and tests over time, not all turned out to be good, so here's what I find when looking through the file:

-changed the falloff formula so the samples are now better used. This has the side effect that AO radius looks now much larger, 1.0r sample radius of say 10.0 has same visual result of 1.1r with sample radius of about 3-4. However settings with same visual result run faster now, especially noticeable for large scale AO.
-changed the blending formula, AO does not kill off IL anymore and vice versa. I think these screenshots show it very well. I didn't use the best scene but it should show that the white door now illuminates the rest while on the old AO code, the IL gets killed away even though I use a stronger IL setting.

-changed the smart sampling formula. Now the far areas don't have a ridiculous low sampling amount anymore which made lower end settings flicker in far areas because you had like 4 samples
-changed the sample distribution a tiny bit so the AO looks better on low sample count.
-changed the sample randomization code for both better sample distribution and less noise so it doesn't need so much more blurring than before. On low sample counts the AO shadowing keeps its shape now, the old code diffused it away.
-tiny change in the AO blurring (actually I just increased the offset) that makes blur smoother now by a small margin
-small fix that reduces the z artifacts with low precision mode almost to 0 so there is no real reason anymore to use high precision
-simplified code of blur tap detection, might improve fps by a little margin but I doubt it will be noticeable

in short: AO looks better, runs faster, features do their job better.

DOWNLOAD

>> Thanks Marty for your awesome work!
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #83

I still have the same problem as with previous version, even cranking up blur still happening (using log depth for GTAV)





Last Edit: 2 years 9 months ago by mindu.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #84

MXAO does not have log depth option so you are using a modiied build. Don't use log depth, just do this: in the GetLinearDepth function there is

float depth=blabla;
depth = somelargeformula;
return depth;

Between the first and the second line, add a line
depth = 1-depth;

and set the far plane (that one parameter with the long ass name) to 1000.0.

I do exactly that on V and it looks like this:
scontent-frt3-1.xx.fbcdn.net/t31.0-8/fr/...jpg?efg=eyJpIjoidCJ9
Last Edit: 2 years 9 months ago by Marty McFly.
The topic has been locked.
The following user(s) said Thank You: mindu

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #85

I love you man, thanks for explain, now is pure beauty :P
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #86

Perfect for Witcher 3.
Last Edit: 2 years 9 months ago by jas01. Reason: )
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #87

hi Marty McFly's i have a problem with MXAO v.1.1r with DOF, instead with the MXAO v.1.0r, decreasing fMXAOBlurSharpness it fix.

The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #88

Custom builds, custom problems. Change shader order and make sure AO runs before DoF.
The topic has been locked.
The following user(s) said Thank You: genstar

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #89

Marty McFly wrote:
Custom builds, custom problems. Change shader order and make sure AO runs before DoF.

He is using the in-game DoF, not Reshades. He is trying to get the AO to not bleed, which is impossible when using in game effects
The topic has been locked.
The following user(s) said Thank You: genstar

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #90

Except disabling in game DoF and using ReShade DoF instead. Or blurring the AO but I won't add some odd AO only DoF..
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #91

Im having a bug with MXAO even with Depth -1

Its the same one noticed on GTA V, i tested with another AO method (you know which) and it works fine, shakes a bit but works fine, while MXAO is all noisy and broken.
Here's two screenshots: i.imgur.com/Sl0Pvz7.jpg (AO amount = 2.0)
i.imgur.com/IW3rIXi.jpg (AO Amount = 4.0)

Game is DX10/11 x64
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #92

That's weird. And it's 1-depth btw. Also, AO amount of 4.0 is way too high, 2.0 should be maximum. What values do you use?
Last Edit: 2 years 9 months ago by Marty McFly.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #93

Ah yeah, i switched to 2.0, its still too much.
0.1 and 0.2 looks fine more or less, it still looks a bit weird.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #94

Hey,

Is there any way I can get this working with Reshade 2.0? I know that this is standalone and such but I would love to know if anyone has had success with getting it to work along with all the standard Reshade effects. Since Reshade 3.0 release date is unknown I would love to get MXAO working in 2.0 till then.


Witanlore: Dreamtime
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #95

As I said before, I disencourage users from creating hacky builds. However MXAO just went ReShade 3.0 format, see ReShade 3.0 shader development section.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #96

Hello,

I've been testing MXAO in DS3 and so far I've only had really nice results but I was wondering about the depth buffer, it is used for MXAO right?
Normally you can't use the depth buffer in online games as far as I know and Reshade disables it automatically when it detects a connection, doesn't it?

Well that doesn't seem the case for MXAO because the depth buffer stays active even when going online, isn't that dangerous?

I don't want to get banned or get my friends banned if I ever give them my preset or just show them some stuff.
The reason I asked is because in some places in DS3 there is a lot of smoke, but I can see objects through that smoke REALLY clearly with MXAO on, but off I cannot see through the smoke at all.
I'm asking because these kinds of things can be abused in online games like CS:GO.

Can anyone shed some light on this? Maybe I'm just wrong and paranoid hehe :P
I'm still kinda new to this scene, but I'm learning and loving it :)

And thank you (Marty MCFly) for MXAO, it really looks amazing! and the performance hit was much better than I was expecting.
Last Edit: 2 years 9 months ago by Kuniyo.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 9 months ago #97

Not an issue of MXAO per se. If reshade does not disable the depth buffer, AO works obviously. Maybe the online mode only produces marginal amounts of traffic and reshade ignores that.
The topic has been locked.
The following user(s) said Thank You: Kuniyo, Swartz27

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 8 months ago #98

@Marty MCFly: This is by far the best AO implementation I have come across. Congratulations, as you sir, are a genius :D

I also have a proposal for you. Is there a way I may privately contact you? I can't seem to find a private message system on this message board.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 8 months ago #99

What are the best mxao config settings for grassy areas in GTA 5?

Using the current config, AO everywhere looks great, but grass looks crazy

#define fMXAOAmbientOcclusionAmount 2.0 //[0.0 to 2.0] Linearly increases AO intensity. Can cause pitch black clipping if set too high.
#define bMXAOIndirectLightingEnable 1 //[0 or 1] Enables Indirect Lighting calculation. Will cause a major fps hit.
#define fMXAOIndirectLightingAmount 8.0 //[0.0 to 8.0] Linearly increases IL intensity.
#define fMXAOIndirectLightingSaturation 0.1 //[0.0 to 3.0] Boosts IL saturation for more pronounced effect.

#define fMXAOSampleRadius 50.0 //[0.5 to 10.0] Sample radius of GI, higher values drop performance.
#define iMXAOSampleCount 74 //[5 to 150] Amount of MXAO samples. Higher means more accurate and less noisy AO at the cost of fps.
#define bMXAOSmartSamplingEnable 1 //[0 or 1] Enables smart sample count reduction for far areas. May look ugly when low sample count (16 or less) is used, turn it off then.
#define fMXAOSampleRandomization 0.25 //[0.0 to 1.0] Breaks up the dither pattern a bit if sample spiral gets too visible (low samples and/or high radius). Needs stronger blurring though.
#define fMXAONormalBias 0.2 //[0.05 to 0.4] Normals bias to reduce self-occlusion of surfaces that have a low angle to each other.
#define bMXAOBackfaceCheckEnable 1 //[0 or 1] For indirect lighting only! Enables back face check so surfaces facing away from the source position don't cast light. It comes with a slight fps drop.
#define bMXAOPerPixelNormalsEnable 1 //[0 or 1] Enables fake per pixel normals embossed from colors. My version is edge aware and distance stable. Adds more detail but may look comic-like. Best for old games.
#define bMXAOLowPrecisionEnable 1 //[0 or 1] Enables lower bit mode for AO source texture (R32F vs R16F). This will improve performance but may introduce some artifacts at distant objects.
#define fMXAOBlurSharpness 1.0 //[0.00 to 2.0] AO sharpness, higher means more sharp geometry edges but noisier AO, less means smoother AO but blurry in the distance.
#define fMXAOBlurSteps 4 //[2 to 7] Offset count for AO smoothening. Higher means more smooth AO but also blurrier AO.

#define fMXAOSizeScale 0.5 //[0.5 to 1.0] Resolution scale in which AO is being calculated.
#define fMXAOMipLevelIL 1 //[0 to 4] Miplevel of IL texture. 0 = fullscreen, 1 = 1/2 screen width/height, 2 = 1/4 screen width/height and so forth.
#define fMXAOMipLevelAO 1 //[0 to 2] Miplevel of AO texture. 0 = fullscreen, 1 = 1/2 screen width/height, 2 = 1/4 screen width/height and so forth. Best results: IL MipLevel = AO MipLevel + 2
#define bMXAODebugViewEnable 0 //[0 or 1] Enables raw AO/IL output for debugging and tuning purposes.







edit:

Also, i found maybe a bug. Does this mxao need a minimum darkness area to where it doesn't apply? The really dark areas in the palm trees and other tree turn whiteish - grey when mxao is turned on. I checked in shader for a 'black / min darkness threshold"



Last Edit: 2 years 8 months ago by turtlevan.
The topic has been locked.

Marty McFly's Ambient Obscurance (MXAO) with IL 2 years 8 months ago #100

The hazy area is just a problem when applying AO on bloom/hazy areas. Game AO is drawn before transparent objects are. Best settings, well, there are not that many config settings to choose from, best is to experiment yourself what meets your fps expectations for instance.
The topic has been locked.