浏览代码

Use a more reasonable depth value

/main
Evgenii Golubev 8 年前
当前提交
0e0ec260
共有 1 个文件被更改,包括 2 次插入3 次删除
  1. 5
      Assets/ScriptableRenderLoop/HDRenderLoop/Sky/Resources/SkyHDRI.shader

5
Assets/ScriptableRenderLoop/HDRenderLoop/Sky/Resources/SkyHDRI.shader


Coordinate coord = GetCoordinate(input.positionCS.xy, _ScreenSize.zw);
// TODO: what sort of depth and world position values do we compute here?
float rawDepth = LOAD_TEXTURE2D(_CameraDepthTexture, coord.unPositionSS).r;
float3 positionWS = UnprojectToWorld(rawDepth, coord.positionSS, _InvViewProjMatrix);
// Pass the depth value near the far plane.
float3 positionWS = UnprojectToWorld(0.01, coord.positionSS, _InvViewProjMatrix);
float4 c1, c2, c3;
VolundTransferScatter(positionWS, c1, c2, c3);

正在加载...
取消
保存