浏览代码

Avoid a compiler warning

/Branch_Batching2
Evgenii Golubev 8 年前
当前提交
2322ea2a
共有 1 个文件被更改,包括 3 次插入1 次删除
  1. 4
      Assets/ScriptableRenderPipeline/ShaderLibrary/AreaLighting.hlsl

4
Assets/ScriptableRenderPipeline/ShaderLibrary/AreaLighting.hlsl


float PolygonIrradiance(float4x3 L)
{
#ifdef SPHERE_LIGHT_APPROXIMATION
[unroll]
for (int i = 0; i < 4; i++)
{
L[i] = normalize(L[i]);

[unroll]
float3 V2 = L[(edge + 1) % 4];
float3 V2 = L[(edge + 1) & 0x3];
F += INV_TWO_PI * ComputeEdgeFactor(V1, V2);
}

正在加载...
取消
保存