Hello!

It looks like you're new here. If you want to get involved, click one of these buttons!

Using 3Dmigoto to remove HUD shaders from dx10/11 games

I was recently introduced to Chiri's 3Dmigoto for changing shaders in dx10/dx11 games the same as what HelixMod allows us to do with dx9 games. 3Dmigoto is still in development but even in it's current state it has a lot of the same features that HelixMod allowed with manipulating shaders in dx9 games. You can find information on the tool and forum on Geforce and GitHub. This wiki post by bo3b is a good place to start if your interested in using the tool.

I'm not very experienced with shaders but went through the task of searching for, finding, and removing the ones that made up the HUD in the Watch_Dogs Madness level and thought I'd share the method used for disabling these and setting up a key toggle.

Finding and marking the HUD shaders
Download the latest release of 3Dmigoto and follow the steps from this wiki page. This will create a ShaderCache folder that it will fill with shaders when the game first loads. This can take awhile, start the process and go make a coffee...finish it, then make another. I found that this would sometimes stall and I would need to force close the game, delete the partial cache it had created and start again. To see it progressing I had the ShaderCache folder open on another monitor where I could see the shader files being created at about one every two seconds depending at what stage the game was loading.

Cycle through the vertex and pixel shaders with the keys below, when you get to one that disables the effect you wan to change or remove then press the marking key. You will hear a beep when the shader has been marked, this will also be copied into the ShaderFixes for you (contrary to notes in the wiki).

vertex shaders - step through with Num1 and Num2, mark with Num3.

Setting up a keybind to toggle/change effects
After finding the shaders you want, you will need to disable shader hunting and add in your toggle.

1. In the d3dx.ini file add the following constant and key to be used for our toggle.
[Constants]
;HUD on by default
x=1
[Key1]
Key=h
; hide HUD
x=0
type=toggle
[Hunting]
hunting=0

Modifying shaders code to remove that effect completely.
Next we want to edit the shader files that were marked and are now in the ShaderFixes folder to remove the effect when our toggle button is pressed.

I'll start with a sample vertex shader that formed part of the HUD in Watch_Dogs. The original shader code is below on t he left with the modified code and highlighted sections on the right.

imageimage

Make these similar changes to each of the shaders you've marked, making sure to only set the values to 0 that are declared as outputs. Some shaders will have only one output while others may have more. Then startup your game and try using the toggle, in this example I used the "h" key as the toggle which was toggling the main menu HUD.

Below is the sample final code for one of my shaders for easy copy past of the toggle code.
cbuffer FireUiPrimitive : register(b0)
{
float4 _ColorAdd : packoffset(c0);
float4 _ColorMultiplier : packoffset(c1);
float4 _DiffuseSampler0Size : packoffset(c2);
float4 _PostFxMaskViewportSize : packoffset(c3);
float4x4 _Transform : packoffset(c4);
float4x4 _UVTransform : packoffset(c8);
float4 _VideoTextureUnpack[8] : packoffset(c12);
float2 _SystemTime_GlitchFactor : packoffset(c20);
float _DesaturationFactor : packoffset(c20.z);
float _DistanceFieldFloatArray[18] : packoffset(c21);
}

Texture2D<float4> StereoParams : register(t125);
Texture1D<float4> IniParams : register(t120);

void main(
float2 v0 : position0,
float2 v1 : texcoord2,
float4 v2 : color1,
out float4 o0 : TEXCOORD0,
out float2 o1 : TEXCOORD1,
out float4 o2 : SV_Position0)
{
float4 r0,r1;
uint4 bitmask, uiDest;
float4 fDest;

float4 params = IniParams.Load(0);
if (params.x == 0)
{
o0 = 0;
o1 = 0;
o2 = 0;
return;
} else {

o0.xyzw = v2.xyzw;
o1.xy = v1.xy;
r0.xy = v0.xy;
r0.zw = float2(1.000000e+000,1.000000e+000);
r1.x = dot(r0.xyww, _Transform._m00_m10_m20_m30);
r1.y = dot(r0.xyww, _Transform._m01_m11_m21_m31);
r0.z = dot(r0.xyzw, _Transform._m03_m13_m23_m33);
o2.z = dot(r0.xyww, _Transform._m02_m12_m22_m32);
r0.xy = r1.xy * float2(2.000000e+000,2.000000e+000) + -r0.zz;
o2.w = r0.z;
o2.xy = float2(1.000000e+000,-1.000000e+000) * r0.xy;
return;
}
}

Watch_Dogs sample
This will disable the main menu HUD in Watch_Dogs Madness Digital Trip level only. It may cause the game to crash if used in any other level (this crashed the game when I tried the toggle in the Spider level). Download and copy the contents into your Watch_Dogs\Bin folder. To temporarily disable rename the d3d11.dll file.

Download Watch_Dogs Madness HUD Toggle

Note: I wasn't able to get the shadercache to create for the Digital trip Spider level (the one I actually wanted this for) as it crashes every time I attempt it. If anyone is able to get a working HUD toggle for that I'd love to know about it.


Further HUD Toggles by The_Janitor using the latest version of 3Dmigato.
I've been able to create a bunch of hud toggles using version 1.1.14 you could try it on Watch Dogs, it might work better than the 1.0.1 version.

Anyway here's the hud toggles I've done so far if anyone wants them:

Deus Ex: Human Revolution
Hitman Absolution
Alien Isolation
Call of Duty Black Ops II
Call of Duty Ghosts
Call of Duty Advanced Warfare
Sniper Elite V2
Mad Max
Ryse
Tomb Raider HUD Toggle
Call of Duty Black Ops III
Assassin's Creed IV
Assassins Creed Syndicate
Splinter Cell Blacklist
Watch Dogs
«13456719

Comments

Sign In or Register to comment.