浏览代码

Rename WriteResult() to StoreResult()

/Yibing-Project-2
GitHub 7 年前
当前提交
e5d0cb44
共有 1 个文件被更改,包括 7 次插入7 次删除
  1. 14
      ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/Resources/SubsurfaceScattering.compute

14
ScriptableRenderPipeline/HDRenderPipeline/Material/Lit/Resources/SubsurfaceScattering.compute


}
}
void WriteResult(uint2 pixelCoord, float3 irradiance)
void StoreResult(uint2 pixelCoord, float3 irradiance)
{
#ifdef USE_INTERMEDIATE_BUFFER
_CameraFilteringTexture[pixelCoord] = float4(irradiance, 1);

[branch] if (distScale == 0 || maxDistInPixels < 1)
{
#if SSS_DEBUG_LOD
WriteResult(pixelCoord, float3(0, 0, 1));
StoreResult(pixelCoord, float3(0, 0, 1));
WriteResult(pixelCoord, albedo * centerIrradiance);
StoreResult(pixelCoord, albedo * centerIrradiance);
#endif
return;
}

float3 viewDirVS = normalize(centerPosVS);
if (dot(normalVS, viewDirVS) >= 0)
{
WriteResult(pixelCoord, float3(1, 1, 1));
StoreResult(pixelCoord, float3(1, 1, 1));
return;
}
#endif

#if SSS_DEBUG_LOD
WriteResult(pixelCoord, useNearFieldKernel ? float3(1, 0, 0) : float3(0.5, 0.5, 0);
StoreResult(pixelCoord, useNearFieldKernel ? float3(1, 0, 0) : float3(0.5, 0.5, 0);
return;
#endif

[branch] if (!useNearFieldKernel)
{
WriteResult(pixelCoord, albedo * totalIrradiance / totalWeight);
StoreResult(pixelCoord, albedo * totalIrradiance / totalWeight);
return;
}

totalIrradiance, totalWeight);
}
WriteResult(pixelCoord, albedo * totalIrradiance / totalWeight);
StoreResult(pixelCoord, albedo * totalIrradiance / totalWeight);
}
正在加载...
取消
保存