Black Mesa

Black Mesa

View Stats:
Deus_nsf Aug 9, 2021 @ 4:47pm
[OBSOLETE] Vulkan performance on Windows is 20% faster than D3D9
FINAL UPDATE : This thread is now obsolete, as the beta version and in the future main version of the game will use DXVK by default :) this is excellent news!

BIG UPDATE: since DXVK 2.1 the shader compilation stutter issue has been completely resolved with a new approach (the guys behind this are geniuses), everything I said below still stands but there's no more stuttering anymore, it's free real estate! Also it's more 20% than 15% now with all the optimizations.

---------------------------------------------------------------------

Since DXVK 1.9.1, Vulkan performs on average 15% faster than the original API (Direct3D9). Can be even more on CPU bound scenarios.
Just drop the 32 bit version of DXVK's d3d9.dll in the Bin folder and the game will be running under Vulkan (you may need to use the old game menu with -oldgameui but it's really no big deal).
You will have a lot of stuttering at the beginning, just like Left 4 Dead 2 Vulkan mode, but once the shader cache is being filled, less and less stutter will occur, to the point of no stutter anymore.

Keep in mind that DXVK will improve a lot since it will be the heart of Proton, the tech that will make Steam Deck possible, so it is possible that the Vulkan performance improves even more within the next months.

EDIT of march 2022:
So it turns out that's exactly what happened, I'm on DXVK 1.10 now and while the performance did improve a little bit, the stuttering and shader cache issues has been significantly reduced, it is an even better experience now! And it's probably not the end of the story!

Also, if you encounter out of memory crashes in game, it is because of the Steam pre-caching option, if for some reason you have this enabled, you want it disabled.
Last edited by Deus_nsf; Mar 13, 2024 @ 7:44pm
< >
Showing 1-15 of 55 comments
Photonboy Aug 10, 2021 @ 12:32pm 
I'm sure Vulkan will improve, but I'm not sure where the focus will be with ProtonDB due to the Steam Deck... that's running on Arch Linux so the optimizations might be more about compatibility and efficiency on Linux rather than the Vulkan API in general as an OS agnostic API.
I'm not a programmer so I'm honestly not sure what part of the software stack is common to both Windows and Linux.
(and I'm sure there will be hardware specific tweaks that focus on the Steam Deck hardware)

That "15%" is going to be highly variable depending on your CPU, GPU, game settings and location in the game.

(It's worth trying DXVX if anybody has FPS drops but if anybody is getting a locked 60FPS or whatever with no stutter obviously there's no point in trying)

SHADER CACHE.
I thought the shader optimizations were meant to optimize to your specific GPU architecture. I don't think you can just copy and paste the files. Perhaps I'm wrong.
Deus_nsf Aug 10, 2021 @ 5:53pm 
Originally posted by Photonboy:
I'm sure Vulkan will improve, but I'm not sure where the focus will be with ProtonDB due to the Steam Deck... that's running on Arch Linux so the optimizations might be more about compatibility and efficiency on Linux rather than the Vulkan API in general as an OS agnostic API.
I'm not a programmer so I'm honestly not sure what part of the software stack is common to both Windows and Linux.
(and I'm sure there will be hardware specific tweaks that focus on the Steam Deck hardware)

That "15%" is going to be highly variable depending on your CPU, GPU, game settings and location in the game.

(It's worth trying DXVX if anybody has FPS drops but if anybody is getting a locked 60FPS or whatever with no stutter obviously there's no point in trying)

SHADER CACHE.
I thought the shader optimizations were meant to optimize to your specific GPU architecture. I don't think you can just copy and paste the files. Perhaps I'm wrong.

You're absolutely right about the shader cache, it can't be shared. Not sure what the solution is there honestly... Except native...

As for DXVK and Proton, I guess for the remake of what is essentially Valve's most important franchise, i sure hope they will land some focus!
The DX9 to Vulkan translation layer is common (that's why they decided to officially use it for L4D2 not too long ago). The full Proton stack isn't supported on Windows though.
Last edited by Deus_nsf; Aug 10, 2021 @ 5:54pm
F. Jardim Aug 11, 2021 @ 7:09am 
Just want to point out this: https://github.com/Joshua-Ashton/dxvk-native

Originally posted by dxvk-native:
DXVK Native is a port of DXVK to Linux which allows it to be used natively without Wine.

This is primarily useful for game and application ports to either avoid having to write another rendering backend, or to help with port bringup during development.

Would be nice to have this on the linux port, as right now it is kind of a mess.

Deus_nsf Aug 11, 2021 @ 10:44am 
Originally posted by Chapolim:
Just want to point out this: https://github.com/Joshua-Ashton/dxvk-native

Originally posted by dxvk-native:
DXVK Native is a port of DXVK to Linux which allows it to be used natively without Wine.

This is primarily useful for game and application ports to either avoid having to write another rendering backend, or to help with port bringup during development.

Would be nice to have this on the linux port, as right now it is kind of a mess.

I don't understand what this brings to the table? It would bypass Wine on Linux and make performance native like?
Photonboy Aug 11, 2021 @ 4:04pm 
Originally posted by Deus:
Originally posted by Chapolim:
Just want to point out this: https://github.com/Joshua-Ashton/dxvk-native



Would be nice to have this on the linux port, as right now it is kind of a mess.

I don't understand what this brings to the table? It would bypass Wine on Linux and make performance native like?
I assumed he was talking about Black Mesa running as a native Linux version. I believe you can do it using ProtonDB instead though I'm not sure if that's the native Linux version with ProtonDB substituted or the Windows version running ProtonDB (on Linux). I don't think you'd use WINE but perhaps I'm wrong.
Last edited by Photonboy; Aug 11, 2021 @ 4:05pm
Deus_nsf Aug 12, 2021 @ 3:22am 
Originally posted by Photonboy:
Originally posted by Deus:

I don't understand what this brings to the table? It would bypass Wine on Linux and make performance native like?
I assumed he was talking about Black Mesa running as a native Linux version. I believe you can do it using ProtonDB instead though I'm not sure if that's the native Linux version with ProtonDB substituted or the Windows version running ProtonDB (on Linux). I don't think you'd use WINE but perhaps I'm wrong.

Proton uses Wine yeah, but Vulkan as a backend instead of OpenGL. But yeah, a native Vulkan version would be amazing.
pjbrs Aug 12, 2021 @ 5:28am 
Well, there is a native linux version, but it's suffering from graphics glitches that probably originate from the dx9 to opengl translation (togl). It would be very interesting to see whether dxvk-native can replace opengl so that linux-native black mesa can fix its bugs.
Deus_nsf Aug 13, 2021 @ 11:37am 
Yeah, remember that silo fight just before launching the rocket? After the fight is over, 95 FPS on D3D9, 113 on Vulkan (looking at the same spot). That's +18 FPS, not bad. Keep in mind that I have a 1080 Ti as well, it's not the most Vulkan efficient GPU out there. I'm actually quite surprised and happy, the shader cache fills itself quite fast, I was able to play from the beginning to surface tension in one session and had no problems whatsoever.
Exostenza Mar 19, 2022 @ 10:41am 
Originally posted by Deus_nsf:
Since DXVK 1.9.1, Vulkan performs on average 15% faster than the original API (Direct3D9). Can be even more on CPU bound scenarios.
Just drop the 32 bit version of DXVK's d3d9.dll in the Bin folder and the game will be running under Vulkan (you may need to use the old game menu with -oldgameui but it's really no big deal).
You will have a lot of stuttering at the beginning, just like Left 4 Dead 2 Vulkan mode, but once the shader cache is being filled, less and less stutter will occur, to the point of no stutter anymore.

Keep in mind that DXVK will improve a lot since it will be the heart of Proton, the tech that will make Steam Deck possible, so it is possible that the Vulkan performance improves even more within the next months.

Absolute legend for the -oldgameui command!

Thank you so much.
Deus_nsf Mar 19, 2022 @ 11:57am 
Originally posted by Exostenza:
Originally posted by Deus_nsf:
Since DXVK 1.9.1, Vulkan performs on average 15% faster than the original API (Direct3D9). Can be even more on CPU bound scenarios.
Just drop the 32 bit version of DXVK's d3d9.dll in the Bin folder and the game will be running under Vulkan (you may need to use the old game menu with -oldgameui but it's really no big deal).
You will have a lot of stuttering at the beginning, just like Left 4 Dead 2 Vulkan mode, but once the shader cache is being filled, less and less stutter will occur, to the point of no stutter anymore.

Keep in mind that DXVK will improve a lot since it will be the heart of Proton, the tech that will make Steam Deck possible, so it is possible that the Vulkan performance improves even more within the next months.

Absolute legend for the -oldgameui command!

Thank you so much.

Well, I invented nothing but here you go!
DXVK also had some pretty nice updates since and runs with much less stuttering pre-cache :)
Exostenza Mar 19, 2022 @ 12:13pm 
Other than the SUPER annoying caching process, which I understand is necessary, the performance of Black Mesa has gone from unplayable in the topside areas due to ridiculous stutter and low fps to a rock solid 120 fps (frame limit) top side and anywhere else while also smooth as butter (as long as there are no new shaders to cache). Running this on my G513QY with Ryzen 5900HX and Radeon 6800m just got orders of magnitude better.

DXVK is an absolute science send.

Also, I was trying to run DXVK but couldn't get the menu up so I thought I had to deal with the absolutely abysmal vanilla performance until I saw OP so thanks so much.

Using DXVK 1.10

I wonder if there is any point trying out the async fork for this as now Black Mesa runs perfectly.
Deus_nsf Mar 19, 2022 @ 12:27pm 
Originally posted by Exostenza:
Other than the SUPER annoying caching process, which I understand is necessary, the performance of Black Mesa has gone from unplayable in the topside areas due to ridiculous stutter and low fps to a rock solid 120 fps (frame limit) top side and anywhere else while also smooth as butter (as long as there are no new shaders to cache). Running this on my G513QY with Ryzen 5900HX and Radeon 6800m just got orders of magnitude better.

DXVK is an absolute science send.

Also, I was trying to run DXVK but couldn't get the menu up so I thought I had to deal with the absolutely abysmal vanilla performance until I saw OP so thanks so much.

Using DXVK 1.10

I wonder if there is any point trying out the async fork for this as now Black Mesa runs perfectly.

yeah the caching is a bit annoying even though it's less annoying now, but it only happens the first time you play the game and as long as you don't update your GPU drivers.

as for the async branch, I have no idea, be my guest!
Deus_nsf Mar 19, 2022 @ 12:43pm 
as for the horrible topside performance, by just lowering the cascade shadow map resolution (I think its the high preset) the dynamic lighting (high as well?) and water to reflect world instead of reflect all, you gain a lot of FPS and sacrifice very little visual quality, except the water in some sections but hopefully the devs will look into the world reflection problems
Myth[Alex] Mar 19, 2022 @ 1:54pm 
Originally posted by Deus_nsf:
yeah the caching is a bit annoying even though it's less annoying now, but it only happens the first time you play the game and as long as you don't update your GPU drivers.
Could you elaborate on this? Does the player have to go through all the game's levels (aka finish it) ? only then is the caching process considered complete? or is it time-based? what's the average wait time? I'm guessing it also depends on the user's GPU "horsepower". Speaking of it, what's the minimum supported video card?

Or it depends per game? I admit I'm new to DXVK and try to gather information. Long story short, how does one know the shader cache is ready? is it when the game experience becomes stutter-free? or is there some sort of notification? any tips?
Deus_nsf Mar 20, 2022 @ 1:37am 
Usually what i tend to do is to play from start to finish yeah, but that was with 1.9.1, last time I tried even after updating my GPU drivers it felt like the caching process was much more simpler.
but yeah, its per game, thing is, some games doesn't cache shaders the same way and there is just no stutters. It's only the case with some game engines, like Source (sadly) and CryEngine for example.
Last edited by Deus_nsf; Mar 20, 2022 @ 1:38am
< >
Showing 1-15 of 55 comments
Per page: 1530 50

Date Posted: Aug 9, 2021 @ 4:47pm
Posts: 55