VOGONS


Source DirectX9 grey fog bug

Topic actions

First post, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

Hi. I'm not sure if you can help me with this or is it even a right place to post it but

There is a problem with older Source titles like Half-Life 2 (mainly original builds) and SiN Emeregence commonly called as grey fog bug. What it looks like: some objects become increasingly grey the further you are from them, sometimes to the point they start to fade right in front of you. The only known workaround if you happen to get it is to force the game into DX8.1 mode or below but that's hardly a solution. I don't know for sure what causes it - video drivers, directx version or combination of both but it seems that it may occur on both nvidia and ati cards. There was also mentioning that enabling Catalyst AI may fix it for ati owners but it's a deprecated feature now.

So the question is: can it be fixed with dgvoodoo's d3d9 emulation? Right now it works exactly the same as without it.
Here are some pics comparing dx 8.1 (normal) and dx 9 (grey)

Attachments

  • pipesdx9.jpg
    Filename
    pipesdx9.jpg
    File size
    53.04 KiB
    Views
    470 views
    File license
    Public domain
  • pipesdx8.jpg
    Filename
    pipesdx8.jpg
    File size
    132.29 KiB
    Views
    470 views
    File license
    Public domain
  • alyxdx9.jpg
    Filename
    alyxdx9.jpg
    File size
    139.71 KiB
    Views
    470 views
    File license
    Public domain
  • alyxdx8.jpg
    Filename
    alyxdx8.jpg
    File size
    150.72 KiB
    Views
    470 views
    File license
    Public domain

Reply 2 of 28, by Dege

User metadata
Rank Oldbie
Rank
Oldbie
ZellSF wrote on 2020-05-09, 13:56:

Not sure how you're hoping Dege can fix this if you don't even know how to reproduce it, but obvious question: does it happen if output API is set to WARP in dgVoodoo settings?

I didn't try it but it seems to be a non-dgVoodoo problem. If the games (with Source engine) are rendering through dx9 then fog is rendered badly unlike via dx8.
Maybe they can be patched...

Which game is the best to try with (other than HL2)?

Reply 3 of 28, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

Well I can reproduce this easily with unpatched retail HL2 that can also be played through steam if you have it. I can PM you instructions on how to install and launch it. I've also seen reports of the same behavior with sin episodes and cs source but I don't have access to this games right now so can't confirm or deny it. Mind you that this is about original retail versions of the games, not the latest updates, at least for valve games.

This is not a dgvoodoo problem, it's how these games works with standart dx9 on current hardware/software

>: does it happen if output API is set to WARP in dgVoodoo settings?
yes

Reply 4 of 28, by Dege

User metadata
Rank Oldbie
Rank
Oldbie

Could you give me a HL2 savegame file plz? I have an HL2 installation to try.

MilkeyWilkey wrote on 2020-05-09, 15:43:

Mind you that this is about original retail versions of the games, not the latest updates, at least for valve games.

So, I guess it was a known problem and they later fixed it in a newer version of the engine.

Reply 5 of 28, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

Sure, here is the save. My game version:

Protocol version 6
Exe version 1.0.1.0 (valve)
Exe build: 12:18:31 Nov 2 2004 (2187)

To all who wonders why even bother with old version here's a quick answer: it's quite different in visuals. different lighting, different shaders, less broken things etc.

So yeah, they might have fixed this with patches, but they also changed too many other things in progress

For SiN there's a very popular scene in pool with many screenshots (Warning, NSFW!) https://steamcommunity.com/app/1300/screenshots/ Just scroll through, you can see shots with both normal shading and with grey gradient.

EDIT: installed Sin Episodes, latest steam version, here's screenshot of the same bug in the very first level

Attachments

Reply 6 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie

For Source games you need to set "ID Type" to "nVidia" under "DirectXExt" (advanced options, right click tab bar in dgVoodooCpl.exe) for them to behave correctly under dgVoodoo in various ways, apparently including fog:

dgvoodoonvidia.jpg
Filename
dgvoodoonvidia.jpg
File size
338.1 KiB
Views
347 views
File license
Fair use/fair dealing exception
dgvoodoo.jpg
Filename
dgvoodoo.jpg
File size
325.66 KiB
Views
347 views
File license
Fair use/fair dealing exception

I'm slightly curious if you can get it working natively on an AMD card by pretending you have a Nvidia card too (3D-Analyze still works?).

Reply 8 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie

The first screenshot looks correct to me, and looks pretty much the same as dxlevel80 (except fog actually looks decent in dxlevel90):

dxlevel80.jpg
Filename
dxlevel80.jpg
File size
38.94 KiB
Views
330 views
File license
Fair use/fair dealing exception

Probably would be helpful if you had a reference image of what you think it's supposed to look like.

Reply 9 of 28, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

If you look closely to the right part of the image you will see that city is much clearer on dx8 shot. also check out this video, it has details of dx8 and water of dx9
https://youtu.be/d6SPTqskrp4?t=209

Reply 10 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie

Yeah, dgVoodoo's fog might be too aggressive (who knows what the developers actually intended it to look like) , here's Nvidia native:

nvidia.jpg
Filename
nvidia.jpg
File size
362.33 KiB
Views
321 views
File license
Fair use/fair dealing exception

Reply 11 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie

I am actually very curious if you can try tricking the game into thinking you have a Nvidia GPU and whether or not the game renders correctly on modern AMD GPUs that way. Can you download 3D-Analyze:
https://www.3dfxzone.it/dir/tools/3d_analyze/download/
Extract that, open 3DAnalyze.exe, set the "VendorID" field to 4318 (Nvidia), select SinEpisodes.exe in "File selection" and then run it?

Obviously, this won't be helpful to Dege in fixing fog under dgVoodoo, but it might be a nice alternative for people who can't run dgVoodoo.

Reply 13 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie
MilkeyWilkey wrote on 2020-05-11, 14:32:

I don't think I can run it with steam
But I do have nvidia machine, laptop to be correct with geforce 710m and intel hd 3000 and it looks the same

Uh? Why can't you run it with Steam? You just tell it to run SinEpisodes.exe , which is in the same location you would put D3D9.dll from dgVoodoo (obviously remove that for this test). As long as Steam is running in the background, the game will launch (I have tried; I used 3D-Analyze to pretend I have an AMD GPU and it had a visible effect).

Reply 15 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie
MilkeyWilkey wrote on 2020-05-11, 14:40:

do you mean selecting the exe and setting ID, then running it from steam? if so then it looks just like without it

No, you need to press the "RUN" button in 3D-Analyze (while Steam is running in the background).

Reply 16 of 28, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

Had to update it to loose beta to work this way because of steam pipe junk. anyway, it looks similar to dgvoodoo with ID Type nVidia

Attachments

Reply 17 of 28, by ZellSF

User metadata
Rank Oldbie
Rank
Oldbie

After some testing I think that's actually correct. With native Nvidia behavior, the fog is so thin it's practically absent in areas where it's supposed to be. It just seems wrong:

aaa 2020-05-11 18-14-59-46.jpg
Filename
aaa 2020-05-11 18-14-59-46.jpg
File size
833.88 KiB
Views
267 views
File license
Fair use/fair dealing exception

If you look at dgVoodoo behavior then you can see fog in the area:

bbb.jpg
Filename
bbb.jpg
File size
829.79 KiB
Views
267 views
File license
Fair use/fair dealing exception

Even if you don't like how it looks, it should be obvious that for dgVoodoo to even render the fog wrong, it would have to be there, and if it's there it should be visible, that just doesn't seem the to be the case on the native Nvidia screenshot. Now you can tell the AMD behavior is so obviously wrong, because the lightning isn't remotely natural (plus the hard edges in the pool scene):

ccc.jpg
Filename
ccc.jpg
File size
845.28 KiB
Views
267 views
File license
Fair use/fair dealing exception

Would like to see dgVoodoo emulate the Nvidia behavior though. I'm not a fan of fog in video games.

Reply 18 of 28, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

While it may seem like so in sin, this looks completely wrong in hl2. Objects look right in current version and with dx8 in the old one. Nvidia emulation again have this grey look on every object although not so prominent as without it

Reply 19 of 28, by MilkeyWilkey

User metadata
Rank Newbie
Rank
Newbie

Here's a comparison of latest HL2 to 1.0 HL2 dx8, buggy dx9 and dgvoodoo with id nvidia. This comparison better illustrate that there is a huge difference between how it's supposed to look (latest+dx8) and the rest. Note that there are difference in lighting with the currect version due to HDR and broken bloom, but it has fog at the same volume and distance as dx8.

@ZellSF, check your native nvidia sin screenshots closely, there is fog, but it's further away, just like in HL2. Also, I think as you have what seems to be a correct look with sin you can also try out 1.0 HL2 and see how it looks for you

There's also the Sin trailer that showcase what seems to be correct look https://www.youtube.com/watch?v=BYzQ89RSyHg

Attachments

  • Filename
    hl2comparison.7z
    File size
    3.72 MiB
    Downloads
    6 downloads
    File license
    Public domain