Skip to content

Commit

Permalink
EnvMap VS: fixed issue with non-separable GL programs
Browse files Browse the repository at this point in the history
  • Loading branch information
TheMostDiligent committed Jan 14, 2025
1 parent 54e1597 commit 40fcccc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions Shaders/Common/private/EnvMap.vsh
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
cbuffer cbCameraAttribs
{
CameraAttribs g_Camera;
CameraAttribs g_PrevCamera;
}

void main(in uint VertexId : SV_VertexID,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,10 +91,10 @@ float ComputeAmbientOcclusionPS(in FullScreenTriangleVSOutput VSOut) : SV_Target
#endif
#if SSAO_OPTION_INVERTED_DEPTH
PositionSS.z *= 1.0 + Epsilon;
#else
#else
PositionSS.z *= 1.0 - Epsilon;
#endif

float3 NormalVS = mul(float4(LoadNormalWS(ScreenCoordUV), 0.0), g_Camera.mView).xyz;
float3 PositionVS = ScreenXYDepthToViewSpace(PositionSS, g_Camera.mProj);
float3 ViewVS = -normalize(PositionVS);
Expand Down

0 comments on commit 40fcccc

Please sign in to comment.