Page 1 of 1

Black Mesa

Posted: Sun Mar 08, 2020 4:53 pm
by masterotaku
The fix is finished as of 2020-03-15.

Blog post: https://helixmod.blogspot.com/2020/03/b ... -2020.html
Fix file https://masterotaku.s3.amazonaws.com/Bl ... ion_fix.7z

Unzip it in the root folder of the game.

IMPORTANT: it's mandatory to set in the Black Mesa profile (bms.exe):
StereoProfile -> Yes
StereoTextureEnable -> 0x00000027

Like in this screenshot:
Image

If you don't do it, effects like water will be broken.

Re: Black Mesa

Posted: Mon Mar 09, 2020 10:20 am
by Shift-E
..and more great news from masterotaku. I was actually just reading the Helix blog comments section for Black Mesa to see if the old fix was somehow playable, now I have my answer.

I never played HL1, and the reviews for Black Mesa have been glowing so I figure I should check this out. thanks for working on this!

Re: Black Mesa

Posted: Tue Mar 10, 2020 3:12 am
by Blacksmith60
Sure, with those reviews I have to own this game, and be a little nostalgic :)

My guess - when using an older driver, the fix will insert an apropiate profile ?

Thanks for working on this masterotaku!

Re: Black Mesa

Posted: Tue Mar 10, 2020 8:06 am
by masterotaku
Blacksmith60 wrote:My guess - when using an older driver, the fix will insert an apropiate profile ?
I'm using 425.31. The profile was already there. Maybe because I launched it before.

It's DX9, so this can't configure profile settings automatically like 3Dmitoto can.

PS: I recommend waiting for the full fix. This WIP is for impatient people :p.

Re: Black Mesa

Posted: Tue Mar 10, 2020 10:27 am
by Shift-E
masterotaku wrote: PS: I recommend waiting for the full fix. This WIP is for impatient people :p.
I am patient, take your time.. :D

Re: Black Mesa

Posted: Tue Mar 10, 2020 5:08 pm
by masterotaku
I have posted the WIP 3 version in the OP. More fixed effects, and hotkey changes and additions.
This is very close to what the final release will be. All that's left is mostly me testing the game to the end.

If you were using a previous version of the fix, delete the shaderoverride folder and replace the rest of the files.

Re: Black Mesa

Posted: Wed Mar 11, 2020 4:13 pm
by masterotaku
Until I upload the next (final?) version, delete the "shaderoverride\vertexshaders\0EAE0430.txt" file. It was causing some geometry corruption.

Re: Black Mesa

Posted: Thu Mar 12, 2020 3:44 am
by bo3bber
bms006_085.jpg
bms032_085.jpg
bms037_085.jpg
bms035_085.jpg
bms026_085.jpg

Re: Black Mesa

Posted: Sun Mar 15, 2020 1:17 pm
by masterotaku
The fix is done. Check the link to the blog post in the OP. If anyone used a WIP fix, delete the "shaderoverride" folder before installing the new one.

Re: Black Mesa

Posted: Sun Mar 15, 2020 4:29 pm
by Blacksmith60
Thanks alot masterotaku, much appreciated, will by this trip down nostalgia lane asap :)

Re: Black Mesa

Posted: Mon Mar 16, 2020 5:57 am
by helifax
Many thanks for this one!

I'm going to HelixVision it this evening! Marvellous job as always!

Re: Black Mesa

Posted: Tue Mar 17, 2020 3:29 am
by skyrimer
Thanks for the fix masterotaku, I'm counting the days until Half Life Alyx releases so this will be a great alternative before HL Alyx arrives.

Re: Black Mesa

Posted: Tue Mar 17, 2020 1:48 pm
by Losti
Do you all know that masterotaku is a f.ucking MACHINE of a SHADERHACKER??

This game is DX9 and this means its not done by RegEx and what ever he has done it fixes obver 1200 shaders!!!!

RESPECT !!!

Image

Re: Black Mesa

Posted: Tue Mar 17, 2020 5:12 pm
by masterotaku
Losti wrote:This game is DX9 and this means its not done by RegEx and what ever he has done it fixes obver 1200 shaders!!!!
Credit for that goes mostly to bo3b. He showed me an example and how to use it the way I wanted :). Then I modified the loops, variables and find/replace strings.

Re: Black Mesa

Posted: Wed Mar 18, 2020 4:24 pm
by Scarhead
Fantastic!
Thanks for your work, master.

Re: Black Mesa

Posted: Sat Mar 21, 2020 12:01 am
by Lundamyrstrollet
Thanks Masterotaku and Bob, absolutely amazing to see this Game after so many Years refreshed and as the best Addition in real 3D!!!
Thanks also to the Black Mesa Team, they've done a great Job since 2012!!!

Re: Black Mesa

Posted: Thu Mar 26, 2020 7:08 am
by whyme466
Thank you for the superb fix, masterotaku! Still working my way through Xen (this new chapter is 4-5X longer that any other chapter of game - Crowbar Collective was very creative in its rework of the original ending chapter). The only issue I found so far is the incorrect depth of some objects in cliff descent area of Chapter 12, Surface Tension (some of the distant cliff walls appear too close, almost like reversed eye display).

Re: Black Mesa

Posted: Thu Mar 26, 2020 8:57 am
by skyrimer
Thanks a lot for this fix Masterotaku, I'll probably play Black Mesa with Vorpx since it works great and for first person games I prefer VR for the extra immersion, but knowing that this was fixed the old fashioned manual way, without regex or anything, is just amazing.

Re: Black Mesa

Posted: Sun Mar 29, 2020 3:02 am
by masterotaku
whyme466 wrote: Thu Mar 26, 2020 7:08 am The only issue I found so far is the incorrect depth of some objects in cliff descent area of Chapter 12, Surface Tension (some of the distant cliff walls appear too close, almost like reversed eye display).
If you mean the mountain you climb down and where you fight a helicopter near the end of it, I say in the blog post precisely what you have to do to make geometry right there:

"Some distant geometry is still close to the camera. This is because that same shader is used for other things. Important example: "DF97175D.txt.ps" in "shaderoverride\vertexshaders". If you uncomment the "//mad r11.x, r10.x, r10.w, r11.x" line, a big texture of a mountain you descend in chapter 12 will be perfect, but it will break some fire attacks of the final boss in chapter 18."

Just remember to revert it after that chapter, because it breaks some attacks of the final boss.

By the way, I added instructions to the blog to make the Nvidia crosshair work correctly. Thanks to Kaimasta for testing that.

Re: Black Mesa

Posted: Mon Mar 30, 2020 4:53 am
by bo3bber
masterotaku wrote: Tue Mar 17, 2020 5:12 pm
Losti wrote:This game is DX9 and this means its not done by RegEx and what ever he has done it fixes obver 1200 shaders!!!!
Credit for that goes mostly to bo3b. He showed me an example and how to use it the way I wanted :). Then I modified the loops, variables and find/replace strings.
This was a great collaboration and a lot of fun working with masterotaku. He is too generous about my help. I did direct him to the Lua mechanism, and how Helix had set this up originally for universal UE3 fixes. And did study it enough to see that we could leverage his work there.

masterotaku took it from there, and whipped up a replacement script faster than I could put one together. His scripting skills are second to none, he picked up Lua and got it working in less than a day.


For anyone interested- the Lua mechanism still works fine on any DX9 game with HelixMod, and the Lua language itself supports a variant of regular expressions, so you can literally do anything you want to find and modify shaders.

Re: Black Mesa

Posted: Mon Jan 09, 2023 4:15 am
by Cer
Hi,

I understand this is a DX9 fix and requires 3Dvision hardware or at least older driver.
As I own a most recent graphic card I have to use the most recent driver.
Therefore I am trying to convert the game output to DX11 using dgVoodo2 and then use Geo-11 to get stereo output. While this seems to work in principle, it is not perfect. In fact I can barely start the game as the menu screen is always black and you have to navigate blindly. Then the game won't stick to the resolution I have set (with disabled DX11 conversion). I also assume that all the shader fixes will not be active since the d3d9.dll from the fix was replaced by the one from dgVoodoo2. When looking at the ini files it seems you can tweak a lot, but I am too new to all this to really understand what is needed and what not.

So, did anyone tried this already? Or, from theory, have some hints what needs to be set where?
Or is my approach nonsense at all because the fixed DX9 shaders won't be used in the DX11 conversion?
You see, I am a bit clueless :cry:

Best regards,
Cer

Re: Black Mesa

Posted: Mon Jan 09, 2023 10:11 am
by 3DNovice
...

Re: Black Mesa

Posted: Tue Jan 10, 2023 12:53 am
by Cer
Uhmmm, I already mentioned to use Geo-11 and yor link seems to be the same. Where is the difference?

Sure it needs a new fix? Shouldn't there a possibility to chain the d3d9.dll calls? So first the DX9 fix is executed which then calls the dgVoodo2 which then calls Geo-11 that finally calls DirectX.
In the Geo config file I have seen an option to specify a Helix Dll to load, but I am mot sure how to underdtand this. Since Geo-11 can't handle DX9 it is for the Dx9 output path??

Re: Black Mesa

Posted: Tue Jan 10, 2023 2:14 am
by masterotaku
When I started the idea of fixing the game, the first thing I tried was dgVoodoo. I saw the black screen problem (which stands even to this day) and thought the game wasn't going to work at all.
So I reluctantly made the fix in DX9.

Even if dgVoodoo worked fully now, a new fix would need to be done from scratch. Nothing about a DX9 fix can be used to make a DX11 fix (except general ideas).

If you have a new GPU, as long as it's Nvidia, you can use the DX9 fix. You just need to install the 3D Vision driver, with 3D Fix Manager for example. DX9 fixes still work with new drivers.

Re: Black Mesa

Posted: Tue Jan 10, 2023 8:05 am
by Cer
At least I found the reason for the black screen:
DgVoodo2 does not suppoert DirectX 9Ex wich is used to render the new menu. But with command line option -oldgameui this can be avoided.

Re: Black Mesa

Posted: Tue Jan 10, 2023 11:06 am
by masterotaku
Cer wrote: Tue Jan 10, 2023 8:05 am At least I found the reason for the black screen:
DgVoodo2 does not suppoert DirectX 9Ex wich is used to render the new menu. But with command line option -oldgameui this can be avoided.
I wish I had known that in 2020. I may take a look at it with dgVoodoo + geo-11. There were some CPU demanding areas that should run better with geo-11.

Re: Black Mesa

Posted: Tue Jan 10, 2023 11:47 am
by Cer
masterotaku wrote: Tue Jan 10, 2023 2:14 am I saw the black screen problem (which stands even to this day) and thought the game wasn't going to work at all.
I thought the same, but didn't want to give up. Took me 2 days to figure that out. I used the debug version of dgvoodo2 and checked the output with debugview. Then I measured the seconds from game start to black screen and checked the log at that time. Here it was written that 9Ex is used and even that it is not supported (as mentioned in the docu). In total it took me 2 days to figure out that the menu is "new" and you can switch back to "old".
masterotaku wrote: Tue Jan 10, 2023 2:14 am Even if dgVoodoo worked fully now, a new fix would need to be done from scratch. Nothing about a DX9 fix can be used to make a DX11 fix (except general ideas).
If you have a new GPU, as long as it's Nvidia, you can use the DX9 fix. You just need to install the 3D Vision driver, with 3D Fix Manager for example. DX9 fixes still work with new drivers.
Too bad. I hoped that the DX9 fix can be applied somehow before the dgVoodo2 kicks in. But honestly, I have no clue about how DirectX and shaders really work.

I do have a new (and powerfull) GPU from NVIDIA, but I also have a good headset (Reverb G2). So I don't really want to play it on my small LCD monitor (with not so good colors).
But even if I want to, I always thought you have to also use the old driver (which I can't). You say I can install just the 3D Vision driver along the newest NVIDIA driver? Then also Helix Vision should work?

Do you know how VorpX works? Would it run on top of your DX9 fix ?

Re: Black Mesa

Posted: Tue Jan 10, 2023 12:26 pm
by masterotaku
Cer wrote: Tue Jan 10, 2023 11:47 am Too bad. I hoped that the DX9 fix can be applied somehow before the dgVoodo2 kicks in. But honestly, I have no clue about how DirectX and shaders really work.
Depending on what I see, refixing the game in DX11 may not be too hard for me. Most of the original difficulty was DX9 fixing quirks that won't be there in DX11. I'll redownload the game today or tomorrow to check that.
Cer wrote: Tue Jan 10, 2023 11:47 am I do have a new (and powerfull) GPU from NVIDIA, but I also have a good headset (Reverb G2). So I don't really want to play it on my small LCD monitor (with not so good colors).
But even if I want to, I always thought you have to also use the old driver (which I can't). You say I can install just the 3D Vision driver along the newest NVIDIA driver? Then also Helix Vision should work?

Do you know how VorpX works? Would it run on top of your DX9 fix ?
HelixVision should work for you (if you have it already, because it's no longer possible to buy it apparently). No idea about VorpX because it's something I don't use (I don't have a VR headset).

Re: Black Mesa

Posted: Tue Jan 10, 2023 5:51 pm
by masterotaku
I've been fixing some effects today in DX11. The DX9 fix helped me find some patterns (with some differences).
And with geo-11, the CPU performance difference is noticeable in the Surface Tension level.

Re: Black Mesa

Posted: Tue Jan 10, 2023 11:45 pm
by Cer
Sounds great, glad I could help you with the black screen issue.
I guess you will release some Geo-11 fix and instructions some days later on?

Re: Black Mesa

Posted: Wed Jan 11, 2023 3:35 am
by masterotaku
Cer wrote: Tue Jan 10, 2023 11:45 pm Sounds great, glad I could help you with the black screen issue.
I guess you will release some Geo-11 fix and instructions some days later on?
I'm doing other things at the same time, so I can't say a specific day or week. Also, if I find some specific problems harder to fix in DX11, it will take more time.

Re: Black Mesa

Posted: Wed Jan 11, 2023 1:39 pm
by Cer
Sure, no need to hurry. At least not for me. Currently I am testing VorpX (which also seems to have shader fixes). Sometime later I would like to compare it with Geo-11 and Katanga.