[SOLVED] MasterEffect Tilt Shift ignores Depth Buffer?

  • utz
  • Topic Author
More
10 years 2 weeks ago #1 by utz MasterEffect Tilt Shift ignores Depth Buffer? was created by utz
The depth buffer visualization shows the UI/HUD in black and the rest of the screen in white. So far so good. Unfortunately the tilt shift effect is applied to the whole image including the gui which makes it useless for playing.
Is this normal behaviour and how can I make it respect the depth buffer?

Game is Neverwinter Nights 2 (directx 9).

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

  • crosire
More
10 years 2 weeks ago #2 by crosire Replied by crosire on topic MasterEffect Tilt Shift ignores Depth Buffer?
TiltShift does not make use of the depthbuffer.
And it showing the GUI is actually really bad, because it's supposed to show the depth information of the game scene.

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

  • utz
  • Topic Author
More
10 years 2 weeks ago #3 by utz Replied by utz on topic MasterEffect Tilt Shift ignores Depth Buffer?
Ok the depth buffer not showing the scene is a different problem.
Is there no quick fix to make tilt shift ignore the gui? If the depth buffer already recognizes it, isn't it possible to add a treshold where the tilt shift is applied? I'm not familiar with shader coding so excuse my ignorance.

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

  • crosire
More
10 years 2 weeks ago #4 by crosire Replied by crosire on topic MasterEffect Tilt Shift ignores Depth Buffer?
Replace line 3378
color.a = TS_BlurAmount;
with
color.a = TS_BlurAmount * saturate(tex2D(SamplerDepth, IN.txcoord).x);

Be aware that this exploits the wrong depth information, will only work in this particular game and may not work anymore in future versions of ReShade.
The following user(s) said Thank You: utz

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 forum. 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.