dxvk icon indicating copy to clipboard operation
dxvk copied to clipboard

[D3D9] Grand Theft Auto San Andreas ENBSeries water effect reflection, and graphics issue.

Open tomjfmu3 opened this issue 2 years ago • 14 comments

It is possible to use ENBSeries with GTA SA, and get everything running smoothly. The only problem it has is setting EnableWater=true inside of enbseries.ini, where whatever is stored in enbwater.fx will not display correctly depending on what ENBSeries mod that you use. The game is off of the store, but there are other ways to get it such as CD version. (Not the definitive edition, the original). I used apitrace with d3d9, and I logged my game in steam. There are some other mods I had, but the ENB has the same problem on a clean install. I had V Graphics ENB to let you know, I also tested it before with SA Direct X 2.0 and it had the same problem.

Software information

  • Grand Theft Auto San Andreas - Steam
  • ENBSeries v0.430

System information

  • GPU: NVIDIA RTX 2060 Mobile
  • Driver: 515.65.01
  • Wine version: GE-Proton7-31
  • DXVK version: 1.10.3

GTa SA Water

Apitrace file(s)

gtasa1.trace

Log files

steam-12120.log

tomjfmu3 avatar Sep 08 '22 06:09 tomjfmu3

Hi there. Could you quickly try and see if making a file called dxvk.conf next to the games exe and inserting d3d9.forceSamplerTypeSpecConstants = True helps the issue? To verify that the conf file gets picked up you can also enable the hud through there see that it shows up ingame dxvk.hud = 1

Blisto91 avatar Sep 08 '22 07:09 Blisto91

Hello, I tested the game with dxvk.conf, and added the lines to it. Heres a picture and the long. The water seems to still not have a reflection. huddxvkScreenshot_2022-09-08_03-53-13 steam-12120.log

tomjfmu3 avatar Sep 08 '22 08:09 tomjfmu3

Oh the issue is missing reflections? Not the color? Or what do you mean. (Missed that part in the title) Does it look correct if you run the game with PROTON_USE_WINED3D=1 %command% to bypass dxvk?

I will check out the trace when i get home if no one else does it before.

Blisto91 avatar Sep 08 '22 08:09 Blisto91

I tried it with PROTON_USE_WINED3D=1 %command% and it had the same problem. I'm starting to think it might just be a proton problem instead. Unless there's any tweak that I could try doing here.

tomjfmu3 avatar Sep 08 '22 08:09 tomjfmu3

~~You probably need to use the Microsoft d3dx9 (not to be confused with d3d9) libraries.~~

Nvm, logs say it has those.

K0bin avatar Sep 08 '22 10:09 K0bin

Hey, this is what it looks like on default windows as a comparison. 20220908204238_1

tomjfmu3 avatar Sep 08 '22 20:09 tomjfmu3

Does the issue also occur when you use dxvk on windows?

Blisto91 avatar Sep 08 '22 21:09 Blisto91

I tried adding the dxvk version of d3d9.dll to the game folder on Windows, but the game is ignoring the dll file on Windows, and it runs the game without dxvk.

tomjfmu3 avatar Sep 09 '22 06:09 tomjfmu3

Did you put it next to the exe? Remember to use either 64bit or 32bit depending on what the exe is. I think it has done before so it should be able to pick it up.

Blisto91 avatar Sep 09 '22 06:09 Blisto91

Yes, I had the gta-sa.exe, and I put the d3d9.dll in the same folder. I used the 32 bit exe, because gta-sa.exe is 32 bit I believe. I am using Windows 10 btw, I don't know if that is the reason.

tomjfmu3 avatar Sep 09 '22 23:09 tomjfmu3

~A while ago, I tried to trace GTA V and my traces were broken in a similar way. IIRC, I determined that the launcher is 32-bit but the game is 64-bit. I didn't spend too much time on it but I wasn't able to get my traces to work in the end, though, even after trying to account for this.~ Meant to comment here: https://github.com/doitsujin/dxvk/issues/2901. The bit about the 64-bit game vs 32-bit launcher might still help here. Not sure if this would apply as far back as San Andreas, though.

renatopereyra avatar Sep 10 '22 02:09 renatopereyra

San Andreas is purely 32 bit I believe, as it was intended for Windows XP and Windows 2000 PCs. But people are modding the heck out of it and running it on later hardware. I know its 32 bit, and I tried both 64 and 32 bit versions of the .dll file just in case, but neither ran. I have a feeling something might be wrong with my Windows installation because it can't run the d3d9 dll in the folder.

tomjfmu3 avatar Sep 10 '22 22:09 tomjfmu3

Could you try making a apitrace on windows without dxvk. I assume the above one is on linux? Just to see if it looks any different.

Blisto91 avatar Sep 14 '22 08:09 Blisto91

I previously ran it in Linux yes. I just ran the game in windows without dxvk. Here's the log: gta-sa.windows.trace

tomjfmu3 avatar Sep 16 '22 06:09 tomjfmu3

Can you verify that this works with current master https://github.com/doitsujin/dxvk/actions/runs/3144484132

Also can you check in the start of the game when you bike towards the water using ENBSeries plus master above that the player sometimes will turn into a sideways torso with invisible limbs?

Blisto91 avatar Sep 29 '22 20:09 Blisto91

Tested some more. Seems the commit that fixes this issue (https://github.com/doitsujin/dxvk/commit/1e1ef8f1bd3970f75f70ef6e4113dcdb30ba0633) is also the commit that causes https://github.com/doitsujin/dxvk/issues/2969

Blisto91 avatar Oct 07 '22 12:10 Blisto91

Fixed according to Bliso.

K0bin avatar Oct 07 '22 19:10 K0bin

I know this is an old issue so there won't be anyone here to answer me but can somebody help me set enb for san andreas on linux? I am trying to set it up for days but the graphics just get messed up with a gray skybox above me, it also doesnt recognize enb i think

FrakezYT avatar Mar 31 '23 18:03 FrakezYT

@FrakezYT I haven't tested without dxvk, but for dxvk just install that into your prefix, or use a launcher that does it for you, and extract enb (the wrapper version containing a d3d9.dll) into the games folder. At least when using Proton i also have to install the Windows version of d3dx9 (or just d3dx9_43 specifically) and d3dcompiler_43 through winetricks/protontricks or else it will crash on launch.

Blisto91 avatar Mar 31 '23 21:03 Blisto91