3D Depth Map Based Stereoscopic Shader

  • otherman
More
7 years 2 weeks ago #921 by otherman Replied by otherman on topic 3D Depth Map Based Stereoscopic Shader
I can help with italian

Please Log in or Create an account to join the conversation.

  • ZapaL
More
7 years 2 weeks ago #922 by ZapaL Replied by ZapaL on topic 3D Depth Map Based Stereoscopic Shader
I can translate into Russian. I tried to do it, instead of words only ????????????
I think the problem is in the code page in ReShade. I asked to fix the multilanguage, yet without an answer.

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 2 weeks ago #923 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader
The I need to start to work on fixing the descriptions then.

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 2 weeks ago - 7 years 2 weeks ago #924 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader
So 1.9.5 is the main Shader now Fully Live.

So many updates and fixes.

Cross_Cusor.fx
The Cross Cursor as you now know is it's own shader. You would have to put this before all other shaders.
Also Fixed spelling mistake.

Polynomial_Barrel_Distortion.fx
Polynomial Barrel Distortion shader now has Profiles Section in side the shader.

Should be easy to edit.

SuperDepth3D.fx
Now with AO for the depth map. This should allow you to have better detail when you zoom in on objects. This should also give objects near you more POP and crevices more depth. I don't know how we can improve any more on with Z-Buffer 3D. But, we come a long way. :woohoo:
Also New automatically adjusting Disocclusion Mask. This should scale with the Depth amount. I recommend radial for VR HMDs.

SuperDepth3D_FlashBack.fx
Has been reworked now should work better and a little faster. Less artifacts on screen and New Setting to allow you to increase the Max Depth in the shader it self. Not as fast as the main shader but, it's still here because this is the code that started it all for me. Also It looks nice in some games. Also got the AO update as the main shader.

I removed the HMD shader since it's now unnecessary. Polynomial Barrel Distortion shader has taken over that job.
I removed the Anaglyph 3D Since it's now merged in to the Main two Shaders SuperDepth3D.fx and FlashBack.fx.
Last edit: 7 years 2 weeks ago by BlueSkyKnight.
The following user(s) said Thank You: Aelius Maximus, hunt1hunt, nemphis

Please Log in or Create an account to join the conversation.

  • x8009
More
7 years 2 weeks ago - 7 years 2 weeks ago #925 by x8009 Replied by x8009 on topic 3D Depth Map Based Stereoscopic Shader
Version 3.0.7 was released on April 1st 2017. !!

no idea how ! xD

reshade.me/

EDIT : Also BlueSkyKnight , there is error with the Experimental SuperDepth3D , it says Error Compiling SamplerCDM or something
EDIT : Also SuperDepth3D_FlashBack has lower performance than the SuperDepth3D , I had some FPS drops in same game BladeStorm Nightmare in the same area with FlashBack but no FPS drop with normal SuperDepth3D so only use FlashBack when there is no choice or something :P

And thanks for the new Shaders ! Awesome with every release xD
Last edit: 7 years 2 weeks ago by x8009.

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 2 weeks ago #926 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader

x8009 wrote: Version 3.0.7 was released on April 1st 2017. !!

no idea how ! xD

reshade.me/

EDIT : Also BlueSkyKnight , there is error with the Experimental SuperDepth3D , it says Error Compiling SamplerCDM or something
EDIT : Also SuperDepth3D_FlashBack has lower performance than the SuperDepth3D , I had some FPS drops in same game BladeStorm Nightmare in the same area with FlashBack but no FPS drop with normal SuperDepth3D so only use FlashBack when there is no choice or something :P

And thanks for the new Shaders ! Awesome with every release xD


SuperDepth3D_FlashBack Performance drop is normal it's a older way of doing 3D.

Don't use the one in the experimental folder. That shader need to be worked on. That one Depth3D. So right now it would give a error since I didn't want people to use it yet.

Please Log in or Create an account to join the conversation.

  • x8009
More
7 years 2 weeks ago - 7 years 2 weeks ago #927 by x8009 Replied by x8009 on topic 3D Depth Map Based Stereoscopic Shader

BlueSkyKnight wrote:

x8009 wrote: Version 3.0.7 was released on April 1st 2017. !!

no idea how ! xD

reshade.me/

EDIT : Also BlueSkyKnight , there is error with the Experimental SuperDepth3D , it says Error Compiling SamplerCDM or something
EDIT : Also SuperDepth3D_FlashBack has lower performance than the SuperDepth3D , I had some FPS drops in same game BladeStorm Nightmare in the same area with FlashBack but no FPS drop with normal SuperDepth3D so only use FlashBack when there is no choice or something :P

And thanks for the new Shaders ! Awesome with every release xD


SuperDepth3D_FlashBack Performance drop is normal it's a older way of doing 3D.

Don't use the one in the experimental folder. That shader need to be worked on. That one Depth3D. So right now it would give a error since I didn't want people to use it yet.


K, gotcha ^^

now with reshade 3.0.7 the order of the shaders stays how you left it and doesn't reorder every refresh or reentering the game.. finally lol, I wish he will keep it updated , it needs a lot of work and many performance enhancement.
Last edit: 7 years 2 weeks ago by x8009.

Please Log in or Create an account to join the conversation.

  • sgsrules
More
7 years 1 week ago #928 by sgsrules Replied by sgsrules on topic 3D Depth Map Based Stereoscopic Shader
Hi BlueSkyDefender, First off awesome work! I was pretty sure that I wouldn't be seeing BOTW in 3d using Nvidia's 3dVision anytime soon since all the real 3d wrappers like helixmod and 3dmigoto only work with directx and Cemu is OpenGL. But thanks to you and helifax (The creater of a OpenGL 3dvision wrapper) I was able to get BOTW working. There are also texture packs for cemu that let you run the game at higher resolutions like 1080p or even 4k. With the newest version of cemu (1.7.4) The game runs at 20-30fps (25 outdoor) on my rig and doesn't have that many bugs.

Anyhow I installed the OpenGL wrapper + reshade and your shader and it looks pretty good so far using the default DM0 except that nearby objects are fairly flat. Do you know if the game uses a linear depth map or is it logarithmic? I see that you're screenshots said you're using dm 6 and looking at the shader:
float cF = 25;
float cN = 0;
depthM = (pow(abs(cN-depthM),cF));
which simplifies to
depthM = pow(depthM,25);

so you're basically raising the depth map by a power of 25 using a power curve. Is there a reason why you can't just sample the depth linearly? Or does raising it by a power work better?

Also whats the best way to test changes to the shader out? Unfortunately Cemu takes a while to load so having to quit and restart everytime i make a change is a pain in the ass. I though about using a laptop and networking in to modify the shader, which is what i do when fixing shaders using 3migoto but i don't know how to reload the shader from within the game. To further complicate things reshade's menu won't work since, probably because I'm using a wrapper for OpenGL.

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #929 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader

sgsrules wrote: Hi BlueSkyDefender, First off awesome work! I was pretty sure that I wouldn't be seeing BOTW in 3d using Nvidia's 3dVision anytime soon since all the real 3d wrappers like helixmod and 3dmigoto only work with directx and Cemu is OpenGL. But thanks to you and helifax (The creater of a OpenGL 3dvision wrapper) I was able to get BOTW working. There are also texture packs for cemu that let you run the game at higher resolutions like 1080p or even 4k. With the newest version of cemu (1.7.4) The game runs at 20-30fps (25 outdoor) on my rig and doesn't have that many bugs.


With the 1.7.4 are you getting a depth map in fullscreen?

sgsrules wrote: Anyhow I installed the OpenGL wrapper + reshade and your shader and it looks pretty good so far using the default DM0 except that nearby objects are fairly flat. Do you know if the game uses a linear depth map or is it logarithmic? I see that you're screenshots said you're using dm 6 and looking at the shader:

float cF = 25;
float cN = 0;
depthM = (pow(abs(cN-depthM),cF));
which simplifies to
depthM = pow(depthM,25);

so you're basically raising the depth map by a power of 25 using a power curve. Is there a reason why you can't just sample the depth linearly? Or does raising it by a power work better?


This code was not made just for CEMU. Also the code your looking at come from a template used to adjust for the differences between game engi. I also have to ask you tested all 40?

As for simplification question I didn't not see a reason to change the code once it worked. Also Since it was from a template I pre-made even before that code was made. I left in the adjustment there so people can see how it works. If you want to delve deeper in the depth precision aspect you would like to read this first. developer.nvidia.com/content/depth-precision-visualized

You also can make your own adjust it with in the shader. If you do not like the one I pre-made.

sgsrules wrote: Also whats the best way to test changes to the shader out?


Use the red/blue 3D glasses in normal mode. It should be easier that way.

sgsrules wrote: Unfortunately Cemu takes a while to load so having to quit and restart everytime i make a change is a pain in the ass. I though about using a laptop and networking in to modify the shader, which is what i do when fixing shaders using 3migoto but i don't know how to reload the shader from within the game. To further complicate things reshade's menu won't work since, probably because I'm using a wrapper for OpenGL.


If you are useing the old version of Depth3D with that game.... well... I cant help you there. I said depth map 6 for SuperDepth3D 1.9.5 for reshade 3.0.

There where a lot of changes since then. Also the new Shader has a new way of dealing with depth up-close.

So download the new one and try it out.
Last edit: 7 years 1 week ago by BlueSkyKnight.
The following user(s) said Thank You: sgsrules

Please Log in or Create an account to join the conversation.

  • sgsrules
More
7 years 1 week ago - 7 years 1 week ago #930 by sgsrules Replied by sgsrules on topic 3D Depth Map Based Stereoscopic Shader
Yes you can get a fullscreen depth image from cemu. I had to change my desktop resolution to match the resolution that was being used in the texure packs before launching cemu, otherwise reshade doesnt work properly. You also need to launch cemu with the -f and -g "game location" for fullscreen and automatically launching a game at startup. You also need to tell cemu to render upside down as well as flipping the depth buffer in your shader settings.

I know that none of your code was specific to Cemu. No i haven't tried all 40 dm settings, and wamted to avoid doing that since it would take forever to randomly test each one out. Using anaglyph glasses without the opengl wrapper seems like a viable solution. But i noticed that you only use a handful of equations with different values for the far and near clipping planes and wanted to figure out what the reasoning for them was. Thanks for linking that article but Im familiar with how a depth buffer is encoded, i mainly wanted to know how the different equations were derived.

Cheers!
Last edit: 7 years 1 week ago by sgsrules. Reason: Fat fingured on mobile phone

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #931 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader

sgsrules wrote: Yes you can get a fullscreen depth image from cemu. I had to change my desktop resolution to match the resolution that was being used in the texure packs before launching cemu, otherwise reshade doesnt work properly. You also need to launch cemu with the -f and -g "game location" for fullscreen and automatically launching a game at startup. You also need to tell cemu to render upside down as well as flipping the depth buffer in your shader settings.


That is good to hear with CEMU 1.7.4. Then this should be easier to adjust for.

sgsrules wrote: I know that none of your code was specific to Cemu. No i haven't tried all 40 dm settings, and wamted to avoid doing that since it would take forever to randomly test each one out. Using anaglyph glasses without the opengl wrapper seems like a viable solution. But i noticed that you only use a handful of equations with different values for the far and near clipping planes and wanted to figure out what the reasoning for them was. Thanks for linking that article but Im familiar with how a depth buffer is encoded, i mainly wanted to know how the different equations were derived.

Cheers!


Ya about the different equations. The problem was that what worked for one game didn't look right for other games...... So I had to figure out how to make the depth map look mostly the same........ Some games really really push it tough.... I am looking at you, "Requiem: Avenging Angel".

In fact my next update I was going to work on a unifying code at least try too. I was looking in to doing just that.

But, ya only though trial and error I got the Depth Map equations. I have not had time refined them since I was working on more important issues. If can you help with this part please do.

Oh.... before I forget. For the AO part in my new shader I did did just use one equation. I guess I could have done my Z-buffer code like that.

It would have cut down on the Depth Maps used.
Last edit: 7 years 1 week ago by BlueSkyKnight.

Please Log in or Create an account to join the conversation.

  • sgsrules
More
7 years 1 week ago #932 by sgsrules Replied by sgsrules on topic 3D Depth Map Based Stereoscopic Shader
Sure I'd love to give a hand.

One more question before i dive into this. The depth map which is generally encoded into a 0-1 range and get's remapped using one of the depth map equations that you're using. What does the final value after the remapping correspond to? Is this the linear depth in eye coordinates (aka view space)? for example in OpenGL you would do something like this:
    float zbufferDepth= texture2D(depthBuffTex, uvCoord).x;
    float zNorm = 2.0 * zbufferDepth- 1.0; //converts from [0]-[1] to [-1]-[1]
    float eyeDepth = 2.0 * zNear * zFar / (zFar + zNear - zNorm * (zFar - zNear));
to obtain the depth in view coordinates from the depth buffer. Or is the DepthM value that you're using in a different coordinate space like clip space?
The following user(s) said Thank You: BlueSkyKnight

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #933 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader

sgsrules wrote: Sure I'd love to give a hand.

One more question before i dive into this. The depth map which is generally encoded into a 0-1 range and get's remapped using one of the depth map equations that you're using. What does the final value after the remapping correspond to? Is this the linear depth in eye coordinates (aka view space)? for example in OpenGL you would do something like this:

    float zbufferDepth= texture2D(depthBuffTex, uvCoord).x;
    float zNorm = 2.0 * zbufferDepth- 1.0; //converts from [0]-[1] to [-1]-[1]
    float eyeDepth = 2.0 * zNear * zFar / (zFar + zNear - zNorm * (zFar - zNear));
to obtain the depth in view coordinates from the depth buffer. Or is the DepthM value that you're using in a different coordinate space like clip space?


Now would this give better results?

I would go to line 678 and test it out.

depthM is the raw depth map. Custom Thirteen should override it. just for testing. since it needs to work with the rest of the code in the shader. The way you grab this is from reshade is this.
texture DepthBufferTex : DEPTH;

sampler DepthBuffer 
	{ 
		Texture = DepthBufferTex; 
	};
Test code
		//Custom Thirteen
		if (Custom_Depth_Map == 13)
		{
                float zNorm = 2.0 *depthM- 1.0;
		float cF = Near_Far.y;//
		float cN = Near_Far.x;//
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		}

I will try this.... On a few opengl games. So I am getting the raw depth input from reshade then from that we try linearization. Now that raw input depends on the game as I understand it.
Last edit: 7 years 1 week ago by BlueSkyKnight.

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #934 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader
Fez Not Good

Amnesia: The Dark Descent Good
Amnesia: A Machin for Pigs Good
quake2xp Good
Rage Good
The Evil Within Good
Wolfenstein: The New Order Good

At this point i'm sure it would work for doom 2016/

Looks good so far with most games. I think, I will treat Fez as a special case. Good Job sgsrules.
So I'm assuming for direct X clip space should be adjust as well. [0,1] range as compared with openGL [-1,1]

A problem with z distribution happens with my other shader flash back. Humm I think I will work on that.
Last edit: 7 years 1 week ago by BlueSkyKnight.
The following user(s) said Thank You: Aelius Maximus

Please Log in or Create an account to join the conversation.

  • sgsrules
More
7 years 1 week ago - 7 years 1 week ago #935 by sgsrules Replied by sgsrules on topic 3D Depth Map Based Stereoscopic Shader
What sort of values are you using for the near and far clip planes? The above equation will linearize depth in view space coordinates, I suspect that the stereo offset values that you calculate in your shader are in clip space coordinates. learnopengl.com/#!Getting-started/Coordinate-Systems If so then you would need to transform the calculated depthM value to clips space my applying a projection transformation. But this is only true if the near and far clip plane values are in the games world or view space coordinates e.g. near= 1 far= 1000 (depending on this games units). Since we don't have access to the projection matrix we can probably just use near and far clip plane values in the -1 to 1 range or 0 to 1 range.

Looks good so far with most games. I think, I will treat Fez as a special case.

Fez is probably using a Orthogonal matrix and doing something funky since it's pseudo 2d/3d so I'm not surprized.

Good Job sgsrules.

Thanks! Glad I could help.

So I'm assuming for direct X clip space should be adjust as well. [0,1] range as compared with openGL [-1,1]

I'm assuming the same things as well since OpenGL and DirectX use similar transformations. The other thing that may be different is that you might have to switch signs for the depth because If i'm not mistaken DirectX uses positive values to go “into” the screen as opposed to OpenGL which uses negative values.

Another thing I would suggest is to optimize your code by reducing the number of conditional if statements. Having conditionals in shaders can often have a serious performance impact on the code. Compilers can sometimes find clever ways to optimize them away, but if your shader code really does have to branch and perform comparisons the speed can drop off significantly.

First off, Instead of having 40 different equations you could reduce the duplicate equations by passing in the cN and cF values as user editable uniform variables. This way you would only have a handful of equations and it would also let the user fine tune the variables.

Another suggestion would be to exit out of the if statement early. Right now even if Depth_Map = 0 the shader still has to evaluate the rest of the 40+ if statements. So instead you could do something like:
	if (Depth_Map == 9)
		{
		float cF = 1;
		float cN = 0.005;
		depthM = cN/(cN-cF) / ( depthM – cF/(cF-cN));
		Color = depthM.rrr; //Sets the final color
		return;// exits the shader
		}
This way it only evaluates the first if statement that is true and sets the final color and skips the rest. Another solution would be to chain your if statements with if else() instead, just keep in mind that there a still a performance cost even if it skips over the following if else statements.

Even better yet use a switch statement with a [call] attribute msdn.microsoft.com/en-us/library/windows...509669(v=vs.85).aspx The call attribute turns the switch statement into a subroutine. If you don't use the call attribute each skipped statement costs 1 cycle so doing a switch with 40 statements would cost you 40 cycles. Using the call statement has about a 5 cycle overhead to setup so if you're using less than 4 or 5 statements it's not necessary. In this case since you have 40+ it's definitely worth it. The call attribute also requires DirectX 10 which should be supported by Reshade 3.0 but if you have issues just leave the [call] out, the switch statement will still perform better than the multiple ifs you currently have in place and the syntax is cleaner as well. Here's some sample code:
float cF = Near_Far.y;//  Near_Far value passed in as a uniform.
float cN = Near_Far.x;//
[call] switch(Depth_Map )
{
	case 0:		//Alien Isolation | Firewatch
		depthM = (exp(depthM * log(cF + cN)) - cN) / cF;
		break;
	case 1: 	//OpenGL Games |Amnesia: The Dark Descent| Soma etc..
		float zNorm = 2.0 *depthM- 1.0;
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		break;
	default:	//Standard DirectX
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		break;
}
Anyhow sorry about the wall of texts but I hope it helps.

Cheers!
Last edit: 7 years 1 week ago by sgsrules.
The following user(s) said Thank You: Aelius Maximus

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #936 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader

sgsrules wrote: What sort of values are you using for the near and far clip planes? The above equation will linearize depth in view space coordinates, I suspect that the stereo offset values that you calculate in your shader are in clip space coordinates. learnopengl.com/#!Getting-started/Coordinate-Systems If so then you would need to transform the calculated depthM value to clips space my applying a projection transformation. But this is only true if the near and far clip plane values are in the games world or view space coordinates e.g. near= 1 far= 1000 (depending on this games units). Since we don't have access to the projection matrix we can probably just use near and far clip plane values in the -1 to 1 range or 0 to 1 range.


0.010 to 1 are the Near to Far value I am using. Ya with reshade we don't have access to the projection matrix. This part of the reason why doing motion blur is hard....

sgsrules wrote: I'm assuming the same things as well since OpenGL and DirectX use similar transformations. The other thing that may be different is that you might have to switch signs for the depth because If i'm not mistaken DirectX uses positive values to go “into” the screen as opposed to OpenGL which uses negative values.

Another thing I would suggest is to optimize your code by reducing the number of conditional if statements. Having conditionals in shaders can often have a serious performance impact on the code. Compilers can sometimes find clever ways to optimize them away, but if your shader code really does have to branch and perform comparisons the speed can drop off significantly.


Will do. I am already rewriting the Depth Map part of the shader. I may Just pass the Near Far Adjustment to the user instead of having 40 presets. But, I am not sure what will be easyer for the user.

I was also thinking doing a side bar with a few basic presets and a slide bar to tune them. I just don't know whats best for the user.

sgsrules wrote: First off, Instead of having 40 different equations you could reduce the duplicate equations by passing in the cN and cF values as user editable uniform variables. This way you would only have a handful of equations and it would also let the user fine tune the variables.


Ya..... I am trying to think of way making it easier for the user I think I have this and a few other test shaders ask the community witch one they like. This will take some time.

sgsrules wrote: Another suggestion would be to exit out of the if statement early. Right now even if Depth_Map = 0 the shader still has to evaluate the rest of the 40+ if statements. So instead you could do something like:

	if (Depth_Map == 9)
		{
		float cF = 1;
		float cN = 0.005;
		depthM = cN/(cN-cF) / ( depthM – cF/(cF-cN));
		Color = depthM.rrr; //Sets the final color
		return;// exits the shader
		}
This way it only evaluates the first if statement that is true and sets the final color and skips the rest. Another solution would be to chain your if statements with if else() instead, just keep in mind that there a still a performance cost even if it skips over the following if else statements.

Even better yet use a switch statement with a [call] attribute msdn.microsoft.com/en-us/library/windows...509669(v=vs.85).aspx The call attribute turns the switch statement into a subroutine. If you don't use the call attribute each skipped statement costs 1 cycle so doing a switch with 40 statements would cost you 40 cycles. Using the call statement has about a 5 cycle overhead to setup so if you're using less than 4 or 5 statements it's not necessary. In this case since you have 40+ it's definitely worth it. The call attribute also requires DirectX 10 which should be supported by Reshade 3.0 but if you have issues just leave the [call] out, the switch statement will still perform better than the multiple ifs you currently have in place and the syntax is cleaner as well. Here's some sample code:
float cF = Near_Far.y;//  Near_Far value passed in as a uniform.
float cN = Near_Far.x;//
[call] switch(Depth_Map )
{
	case 0:		//Alien Isolation | Firewatch
		depthM = (exp(depthM * log(cF + cN)) - cN) / cF;
		break;
	case 1: 	//OpenGL Games |Amnesia: The Dark Descent| Soma etc..
		float zNorm = 2.0 *depthM- 1.0;
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		break;
	default:	//Standard DirectX
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		break;
}


I will work on this and see if can get away with most of this. Ya most of the time I will have to consider dx9 since it's been limiting the freedom I have as compared to dx10+ and opengl. This is good stuff.

sgsrules wrote: Anyhow sorry about the wall of texts but I hope it helps.


Thank you for the Help. I need information like this to learn. More help like this what I love. I need more walls of text like this. It's all helpful information.
Last edit: 7 years 1 week ago by BlueSkyKnight.
The following user(s) said Thank You: Aelius Maximus

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #937 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader
With the help of sgsrules 1.9.6 will come out a whole lot sooner. Also I have been planing on working on the 1.9.6 Depth Map code anyways.

I have been hearing to the feed back. I also been looking at different youtubers complaints. I am making the Depth Map System much easier to adjust.

I am going to try to do away with most profiles. This while keeping compatibility with games like fez. ;) I already have the new code working really just need to test all the odd ball games.

Experimental v1.9.6 will be up soon after I test out most games.

Also as much as I want to use the flow control switch statements they incompatible with dx9 it seems... But, since I am removing most profiles it will not change much anyways.

Also Hope to have this shader ready with some settings by April 9th since that when most of you guys get to play Breath of the Wild.
Last edit: 7 years 1 week ago by BlueSkyKnight.
The following user(s) said Thank You: Aelius Maximus

Please Log in or Create an account to join the conversation.

  • sgsrules
More
7 years 1 week ago - 7 years 1 week ago #938 by sgsrules Replied by sgsrules on topic 3D Depth Map Based Stereoscopic Shader

Also as much as I want to use the flow control switch statements they incompatible with dx9 it seems... But, since I am removing most profiles it will not change much anyways.

You can still use a switch statement on dx9 and older hardware just don't use the [call] attribute so the switch would look like:
switch(Depth_Map )
{
	case 0:		//Alien Isolation | Firewatch
		depthM = (exp(depthM * log(cF + cN)) - cN) / cF;
		break;
	case 1: 	//OpenGL Games |Amnesia: The Dark Descent| Soma etc..
		float zNorm = 2.0 *depthM- 1.0;
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		break;
	default:	//Standard DirectX
		depthM = 2.0 * cN * cF / (cF + cN - zNorm * (cF - cN));
		break;
}
Last edit: 7 years 1 week ago by sgsrules.
The following user(s) said Thank You: Aelius Maximus

Please Log in or Create an account to join the conversation.

  • crosire
More
7 years 1 week ago #939 by crosire Replied by crosire on topic 3D Depth Map Based Stereoscopic Shader
This is ReShade FX, not HLSL, switch statements work everywhere. But the emulation for Dx9 is limited, as such ReShade will print a warning when it encounters any.
The following user(s) said Thank You: Aelius Maximus

Please Log in or Create an account to join the conversation.

  • BlueSkyKnight
  • Topic Author
More
7 years 1 week ago - 7 years 1 week ago #940 by BlueSkyKnight Replied by BlueSkyKnight on topic 3D Depth Map Based Stereoscopic Shader
CEMU and Shifting depth map issue. The Depth Map LOZ:BOTW Seems to shift based on camera position. So even if you find the right values once you move it will shift.

Have only seen this problem once before with one of the S.T.A.L.K.E.R games.

>.> But, if you want a depth map in game you need to set your graphicsPacks Override this if you have a 1080p monitor.
[Definition]
titleIds = 50000101c9500
name = "The Legend of Zelda: Breath of the Wild"

[TextureRedefine]
width = 1280
height = 720
overwriteWidth = 1920
overwriteHeight = 1080
Just change the overwriteWidth & overwriteHeight.
Last edit: 7 years 1 week ago by BlueSkyKnight.

Please Log in or Create an account to join the conversation.

We use cookies
We use cookies on our website. Some of them are essential for the operation of the forum. You can decide for yourself whether you want to allow cookies or not. Please note that if you reject them, you may not be able to use all the functionalities of the site.