thanks a lot! I'm currently trying to make my deferred renderer better and wanted to use z-Reconstrunction for the world coords in order to keep the gBuffer slim.

oh and talking about useful shader code (and if you don't mind contributing), this might be helpful as well (especially for SSAO or RLR):
convert world- to screen-space coordinates
Code:
float2 worldToScreenSpace(float3 worldPos)
{
	float3 temp = mul(worldPos - vecViewPos.xyz, matViewProj);
	
	temp *= 1 / temp.z; // normalize to z = 1
	return temp.xy * float2(0.5, -0.5) + 0.5 + vecViewPort.zw * 0.5; // final coords
}



POTATO-MAN saves the day! - Random