Depth buffer detection modifications

  • thalixte
  • Topic Author
More
4 years 10 months ago #841 by thalixte Replied by thalixte on topic Depth buffer detection modifications

Koubarov wrote: Update regarding Skyrim.

I had to disable the weapon and stencil fixes in order to get an almost perfect Depth Buffer.

Objects no longer disappear from the Depth Buffer while panning the camera although at times some flickering (Depth Buffer turns off for a split second) and minor artifacts at the bottom of the screen are occurring. Most of the time it works so definitely an improvement.

Lastly there is a weird bug happening that I don't know if it's the modified .dll that does it or Marty's Quint MXAO.

If I enable MXAO_Quint from the start, the main menu screen and loading screen are blackened severely and the other Depth Buffer effects (namely Adaptive Fog) can't access the Depth Buffer in game, if then I force a reload of ReShade everything works as intended and when exiting to the main menu there is no blackening of the 2D image.

To remedy this I have ΜΧΑΟ_Quint disabled in my profile and I re-enabled (through a key stroke) it on the first in-game load of my save game and everything works fine after that.


Thks for your feedback. Have you tried to enable the "Focus on the best original depthstencil source" checkbox to see if it removes the blacken in the main menus ?

For the weapon, have you try to tick the "Fix for user weapon or cockpit" checkbox ?
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago #842 by thalixte Replied by thalixte on topic Depth buffer detection modifications

0nimare wrote:

thalixte wrote: Is it with the mod ?
Could you please send a video of the pb, displaying the dx9 tab ? Thks.


It actually happens in just hl2upd and vanilla hl2

HL2:Update with auto preserve (223 mb)
HL2:Update with index 1 preserved (509 mb)
Vanilla HL2 with auto preserve (246 mb)
Vanilla HL2 with index 1 preserved (231 mb)


Can you test this one ?
d3d9_hl2.zip
The following user(s) said Thank You: 0nimare
The topic has been locked.
  • 0nimare
More
4 years 10 months ago - 4 years 10 months ago #843 by 0nimare Replied by 0nimare on topic Depth buffer detection modifications
Thanks a lot! Works perfectly for vanilla and update. Tested all maps and places that had issues before.
Settings:
[DX9_BUFFER_DETECTION]
DisableINTZ=0
PreserveDepthBuffer=1
PreserveDepthBufferIndex=4294967295
AutoPreserve=0
BruteForceFix=0
FocusOnBestOriginalDepthstencilSource=0

Works almost perfectly in hl2:update:mmod, occasionally when rotating camera depth buffer becomes empty for like a frame causing a flicker.
Also if I change any setting when map is loaded will cause rendering issue, like making whole map invisible, flickering map parts, background part displaying in front , BUT if I just launch the game with settings above and don't change anything it doesn't happen. FocusOnBestOriginalDepthstencilSource=1 fixes the rendering issue but makes weapon and doors invisible on depth buffer. Alt-tabbing also seems to cause or fix the rendering issue.

Thanks again!

Update: i.imgur.com/bCdlth5.jpg - another issue, happens with PreserveDepthBuffer=1 in update, update:mmod, but not in vanilla hl2
Last edit: 4 years 10 months ago by 0nimare.
The topic has been locked.
  • Koubarov
More
4 years 10 months ago - 4 years 10 months ago #844 by Koubarov Replied by Koubarov on topic Depth buffer detection modifications

thalixte wrote:
Thks for your feedback. Have you tried to enable the "Focus on the best original depthstencil source" checkbox to see if it removes the blacken in the main menus ?

For the weapon, have you try to tick the "Fix for user weapon or cockpit" checkbox ?


Updated feedback on Skyrim. None of the above options fixes the blackened problem in the main menu in Skyrim on first load.

The "Focus on the best original depthstencil source" fixes the occasional artifacts which appear at the bottom of the screen though it increases the depth buffer flickering so from the two evils I prefer less depth buffer flickering and I keep it disabled.

Actually both the fixes increase the frequency of Depth Buffer flickering so I have them both deactivated.
Last edit: 4 years 10 months ago by Koubarov.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago #845 by thalixte Replied by thalixte on topic Depth buffer detection modifications

0nimare wrote: Thanks a lot! Works perfectly for vanilla and update. Tested all maps and places that had issues before.
Settings:

[DX9_BUFFER_DETECTION]
DisableINTZ=0
PreserveDepthBuffer=1
PreserveDepthBufferIndex=4294967295
AutoPreserve=0
BruteForceFix=0
FocusOnBestOriginalDepthstencilSource=0

Works almost perfectly in hl2:update:mmod, occasionally when rotating camera depth buffer becomes empty for like a frame causing a flicker.
Also if I change any setting when map is loaded will cause rendering issue, like making whole map invisible, flickering map parts, background part displaying in front , BUT if I just launch the game with settings above and don't change anything it doesn't happen. FocusOnBestOriginalDepthstencilSource=1 fixes the rendering issue but makes weapon and doors invisible on depth buffer. Alt-tabbing also seems to cause or fix the rendering issue.

Thanks again!

Update: i.imgur.com/bCdlth5.jpg - another issue, happens with PreserveDepthBuffer=1 in update, update:mmod, but not in vanilla hl2


And with this one ?

d3d9_hl2.zip
The topic has been locked.
  • 0nimare
More
4 years 10 months ago - 4 years 10 months ago #846 by 0nimare Replied by 0nimare on topic Depth buffer detection modifications
I think this one made it worse
imgur.com/a/bni2aii
Last edit: 4 years 10 months ago by 0nimare.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago #847 by thalixte Replied by thalixte on topic Depth buffer detection modifications

0nimare wrote: I think this one made it worse
imgur.com/a/bni2aii


And with this one, same pb ?

d3d9_hl2.zip
The topic has been locked.
  • dedicateddark
More
4 years 10 months ago - 4 years 10 months ago #848 by dedicateddark Replied by dedicateddark on topic Depth buffer detection modifications
Reshade 4.2.1 seems to not be able to access the depth buffer on Arkham Asylum, so far I have tried turning off the MSAA, lowering all the settings & cut-off internet connection. As well as cycling through every available setting on the depth buffer.

Wanted to tryout the path tracing shader on the game. And also MXAO. Help would be much appreciated. I have no idea on how to compile or code or anything, so can't do anything with github links.
Last edit: 4 years 10 months ago by dedicateddark.
The topic has been locked.
  • 0nimare
More
4 years 10 months ago #849 by 0nimare Replied by 0nimare on topic Depth buffer detection modifications

thalixte wrote: And with this one, same pb ?

d3d9_hl2.zip

Yep, same issue. I tried playing in windowed (so there is no alt tab) ignoring small rendering glitches but crashed few times. I assume crash happens when game tries to unload bugged model - killing enemies, map changing or just going back to main menu.
The topic has been locked.
  • Koubarov
More
4 years 10 months ago - 4 years 10 months ago #850 by Koubarov Replied by Koubarov on topic Depth buffer detection modifications
Update 2 on Skyrim.

I managed to eliminate the blackening problem which seems related to the new HQ Ground-Truth AO mode in MXAO_Quint.

I reverted back to the normal AO mode and the problem is solved no longer the menu gets darkened on first load.

Plus I managed to solve the problem of AO "stealing" the Depth Buffer by moving Adaptive Fog at the top with ΜΧΑΟ following after.

Now both effects are working as intended on first load and no longer a reload is needed.

So to sum it up, so far it seems that the disparity between the Depth Buffer and Viewport on internal cells is solved (at least to the dungeons I've checked).

Plus on external cells Depth Buffer works as intended but with flickering and minor artifacts at the bottom of the screen at times.
Last edit: 4 years 10 months ago by Koubarov.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago - 4 years 10 months ago #851 by thalixte Replied by thalixte on topic Depth buffer detection modifications

dedicateddark wrote: Reshade 4.2.1 seems to not be able to access the depth buffer on Arkham Asylum, so far I have tried turning off the MSAA, lowering all the settings & cut-off internet connection. As well as cycling through every available setting on the depth buffer.

Wanted to tryout the path tracing shader on the game. And also MXAO. Help would be much appreciated. I have no idea on how to compile or code or anything, so can't do anything with github links.


Here is the last dll:
d3d9.zip

For me, works good with those settings:
[DX9_BUFFER_DETECTION]
DisableINTZ=0
PreserveDepthBuffer=1
PreserveDepthBufferIndex=0
AutoPreserve=1
FocusOnBestOriginalDepthstencilSource=0
BruteForceFix=0
Last edit: 4 years 10 months ago by thalixte.
The following user(s) said Thank You: jas01, dedicateddark
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago - 4 years 10 months ago #852 by thalixte Replied by thalixte on topic Depth buffer detection modifications

Koubarov wrote: Update 2 on Skyrim.

I managed to eliminate the blackening problem which seems related to the new HQ Ground-Truth AO mode in MXAO_Quint.

I reverted back to the normal AO mode and the problem is solved no longer the menu gets darkened on first load.

Plus I managed to solve the problem of AO "stealing" the Depth Buffer by moving Adaptive Fog at the top with ΜΧΑΟ following after.

Now both effects are working as intended on first load and no longer a reload is needed.

So to sum it up, so far it seems that the disparity between the Depth Buffer and Viewport on internal cells is solved (at least to the dungeons I've checked).

Plus on external cells Depth Buffer works as intended but with flickering and minor artifacts at the bottom of the screen at times.


Just to check, can you try this last one (not sure it will resolve your flickerings):
d3d9.zip ?

Also, can you submit a video of the flickering pb ? Thks a lot.
Last edit: 4 years 10 months ago by thalixte.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago #853 by thalixte Replied by thalixte on topic Depth buffer detection modifications

0nimare wrote:

thalixte wrote: And with this one, same pb ?

d3d9_hl2.zip

Yep, same issue. I tried playing in windowed (so there is no alt tab) ignoring small rendering glitches but crashed few times. I assume crash happens when game tries to unload bugged model - killing enemies, map changing or just going back to main menu.


A last try:
d3d9_hl2.zip
The following user(s) said Thank You: 0nimare, XPzKiber, iTest
The topic has been locked.
  • 0nimare
More
4 years 10 months ago - 4 years 10 months ago #854 by 0nimare Replied by 0nimare on topic Depth buffer detection modifications
[DX9_BUFFER_DETECTION]
DisableINTZ=0
PreserveDepthBuffer=1
PreserveDepthBufferIndex=4294967295
AutoPreserve=1
BruteForceFix=0
FocusOnBestOriginalDepthstencilSource=0

I think you've made it! The only issue is a flicker when depth buffer switches. Thanks!

Update: there were some rendering issues after alt tabbing in fullscreen - fixed by going borderless windowed
Sometimes crashes when map changes, not sure why it happens, I assume after messing with shader settings or maybe just recompiling them - if I just launch the game with shaders set to performance mode and don't touch them it works fine
Last edit: 4 years 10 months ago by 0nimare.
The topic has been locked.
  • Insomnia
More
4 years 10 months ago #855 by Insomnia Replied by Insomnia on topic Depth buffer detection modifications
I can't believe I've missed out on this for so long.
Thank you for releasing this.

Is it available for OpenGL as well? Would love to use this for Doom 3. :D
The topic has been locked.
  • x8009
More
4 years 10 months ago - 4 years 10 months ago #856 by x8009 Replied by x8009 on topic Depth buffer detection modifications
Stated happen with 4.3.0 when I alt tab for example in NFS Payback I get this

Any idea what is the issue ?

In the pictures it shows the Distortion when alt tabbing , then the Depth View issue then after clicking Reload depth view and normal . It doesn't cause issue when first launching the game , I do use AfterBurner to take the screenshots and such but I don't think that what causing the issue. it was working fine before it.

Only Reload button fix the issue, no other changes , changing depth buffer, disabling shaders fix the issue.
To fix it I need to open the Reshade menu and Reload , then it fixes the issue, with 4.2.x it didn't happen or many versions before.







Last edit: 4 years 10 months ago by x8009.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago #857 by thalixte Replied by thalixte on topic Depth buffer detection modifications

Insomnia wrote: I can't believe I've missed out on this for so long.
Thank you for releasing this.

Is it available for OpenGL as well? Would love to use this for Doom 3. :D


Unfortunately, it is not for the moment. If i have some times, i will, but maybe the priority is on dx12 implementation, i guess.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago - 4 years 10 months ago #858 by thalixte Replied by thalixte on topic Depth buffer detection modifications

Sweren wrote: Hi, I'm looking for a way to make depth buffer work on Euro Truck Simulator 2 (DX11)

I don't know nothing about coding so I can't use your repository, excuse me :)


Just tested, but it only works in DX9 for me.
Unfortunately, i will not be able to retrieve a valid depth buffer for this specific game. It uses a special viewport, and, most of all, to retrieve the db correctly, Reshade needs to have access to the transformation matrices of the game, because the db texture is not placed accordingly to the player's view.
Last edit: 4 years 10 months ago by thalixte.
The topic has been locked.
  • thalixte
  • Topic Author
More
4 years 10 months ago #859 by thalixte Replied by thalixte on topic Depth buffer detection modifications

x8009 wrote: Stated happen with 4.3.0 when I alt tab for example in NFS Payback I get this

Any idea what is the issue ?

In the pictures it shows the Distortion when alt tabbing , then the Depth View issue then after clicking Reload depth view and normal . It doesn't cause issue when first launching the game , I do use AfterBurner to take the screenshots and such but I don't think that what causing the issue. it was working fine before it.

Only Reload button fix the issue, no other changes , changing depth buffer, disabling shaders fix the issue.
To fix it I need to open the Reshade menu and Reload , then it fixes the issue, with 4.2.x it didn't happen or many versions before.


Just tested with Reshade 4.3, and i was not able to reproduce the pb. Not sure it is Reshade related.
The topic has been locked.
  • Pat_s2
More
4 years 10 months ago - 4 years 10 months ago #860 by Pat_s2 Replied by Pat_s2 on topic Depth buffer detection modifications
thalixte would you happen to have a correct dxgi.dll for crysis 1? i can not get the depth buffer to show up to save my live and I wanna try out the new raytracing shader <3 possibly garrys mod as well. i tried your hl2 one with hope but it doesnt work.
Last edit: 4 years 10 months ago by Pat_s2.
The topic has been locked.
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.