VOGONS


First post, by BEEN_Nath_58

User metadata
Rank l33t
Rank
l33t

This game uses Direct3D Retained Mode as well as Direct3D Ramp Emulation for the 2D version. The 3D version works more or less the same with or without dgVoodoo2. The 2D version has issues, in Windows 10/11, the mission render is incomplete and it only renders the sky. dgVoodoo2 fixes it and the game renders quite fine.

Now the problem I faced can be traced from some specific points: Mission - Tunnel Race Level 1. Here, I find that the tree in 2D version has a white outlining for some reason. When you ride the scooter and reach the tunnel (which is white from outside), you will see that the tunnel is white inside in colour.

Now the comparison starts from Windows 98 and Windows 7. Both of them can play the game without dgVoodoo2. On both OS, the tunnel inside is opaque blue and the tree near the start line has no white outlining, something which doesn't match dgVoodoo2.

DxWnd is also trying to emulate the same on the RGB device instead (and has been quite successful except the tunnel is transparent glass now), so a discovery on how the game should look can help both softwares.

Attachments

previously known as Discrete_BOB_058

Reply 1 of 7, by Dege

User metadata
Rank l33t
Rank
l33t

No3D version renders through the Ramp device I guess, which is a pure software renderer with poor rendering capabilities targeting performance (on '90s cpu's).
It can only do mono-rendering that's why certain elements like tree's and tunnel textures are modulated only by shades of white or rendered in their natural form. I'm not sure if Ramp device can do alpha blending, that's why the tunnel is not transparent from the inside.
Anyway, I found a bug in dgV that caused white or rainbow-colored speculars here and there, I fixed it.
The tree texture is an antialiased tree figure on a pure white background that's why white outline appears with Ramp. On non-ramp it's modulated with a dark color so the outline is not so noticable.

Reply 2 of 7, by BEEN_Nath_58

User metadata
Rank l33t
Rank
l33t
Dege wrote on 2022-08-12, 14:55:

It can only do mono-rendering that's why certain elements like tree's and tunnel textures are modulated only by shades of white or rendered in their natural form. I'm not sure if Ramp device can do alpha blending, that's why the tunnel is not transparent from the inside.

file.php?mode=view&id=143271

Shadows of the Empires talk about certain missing Ramp features on Windows 11. Is alpha blending one of the one from the list? This list isn't necessarily all features of Ramp, but I see many ALPHA entries so I added.

Basically, DxWnd's dev noticed that the texture should have a changing shade and shouldn't be transparent:

https://sourceforge.net/p/dxwnd/discussion/ge … 9e/?page=3#dd20

The issue currently there is to achieve the perfect shade transition.

Attachments

previously known as Discrete_BOB_058

Reply 3 of 7, by Dege

User metadata
Rank l33t
Rank
l33t

1) I looked into and Ramp device indeed does not support alpha blending. That's why tunnel is opaque with no3D.

2) When the tunnel is rendered from inside then the material used for the lighting has 'diffuse' RGBA value with alpha = 0.5, and that should flow into the result of the lighting without alteration. Also, the game simply sets SRCBLEND and DSTBLEND to SRCALPHA and INVSRCALPHA respectively and toggles ALPHABLENDENABLE to false/true depending on the mesh being rendered. When true then the alpha value is taken from the vertex diffuse which is 0.5, that's why it's transparent (meant to be glass?).

I don't know why you get opaque results, it's weird because the vertex processing is done in software, independent on the GPU and driver. I also searched for it on youtube and found this (it's from 2011, I think it must be Win7):
https://youtu.be/E5DFK9K6uiw?t=731

Edit: maybe the version of D3DRM.DLL is important. Mine is the latest (350,208 bytes).

Reply 4 of 7, by BEEN_Nath_58

User metadata
Rank l33t
Rank
l33t
Dege wrote on 2022-08-12, 18:21:

1) I looked into and Ramp device indeed does not support alpha blending. That's why tunnel is opaque with no3D.

Okay that makes sense. Windows XP, 7 and 98 all have opaque tunnels

Dege wrote on 2022-08-12, 18:21:

I don't know why you get opaque results, it's weird because the vertex processing is done in software, independent on the GPU and driver. I also searched for it on youtube and found this (it's from 2011, I think it must be Win7):
https://youtu.be/E5DFK9K6uiw?t=731

Edit: maybe the version of D3DRM.DLL is important. Mine is the latest (350,208 bytes).

@ghotik2002 - "I just forced a SetRenderState D3DRENDERSTATE_CULLMODE, 1 in the execute buffer and here the result: quite similar to dgVooDoo2 and with the concrete texture visible from inside!!". Well we have concrete texture, but the textures don't share the similar opaqueness as Win98-7.

May I ask how the game behaves with no3D executable on your end? If you can get opaque tunnels, which DxWnd is trying for.

Dege wrote on 2022-08-12, 18:21:

2) When the tunnel is rendered from inside then the material used for the lighting has 'diffuse' RGBA value with alpha = 0.5, and that should flow into the result of the lighting without alteration. Also, the game simply sets SRCBLEND and DSTBLEND to SRCALPHA and INVSRCALPHA respectively and toggles ALPHABLENDENABLE to false/true depending on the mesh being rendered. When true then the alpha value is taken from the vertex diffuse which is 0.5, that's why it's transparent (meant to be glass?).

DxWnd team will read it... but the glass shouldn't exist (game devs shouldn't be dumb enough to think you can see a thing outside an opaque object, outside being white)

previously known as Discrete_BOB_058

Reply 5 of 7, by BEEN_Nath_58

User metadata
Rank l33t
Rank
l33t

Mr. Dege, the tunnel looks like this without dgVoodoo2 on Windows 95 to Windows 7.

Attachments

previously known as Discrete_BOB_058

Reply 6 of 7, by BEEN_Nath_58

User metadata
Rank l33t
Rank
l33t

I installed Windows 10 1709, and Ramp works correctly there. However, Ramp was broken in Windows 10 1809.

And again, the wall glass is all blue instead of white:

file.php?mode=view&id=154908

So Windows 98 - Windows 10 1709 all have similar graphics, I don't see a reason that it should be white.

Update: I installed Win10 1803 update and Ramp works. After updating to 1809 again, it breaks. So I revert to 1803 now.

Attachments

previously known as Discrete_BOB_058