浏览代码

Remove dead code

/main
Evgenii Golubev 8 年前
当前提交
847d26fc
共有 1 个文件被更改,包括 1 次插入3 次删除
  1. 4
      Assets/ScriptableRenderLoop/ShaderLibrary/ImageBasedLighting.hlsl

4
Assets/ScriptableRenderLoop/ShaderLibrary/ImageBasedLighting.hlsl


// TODO: optimize!
float perceptualRoughnessToMipmapLevel(float perceptualRoughness, float NdotR)
{
// return perceptualRoughnessToMipmapLevel(perceptualRoughness);
float m = PerceptualRoughnessToRoughness(perceptualRoughness);
float m = PerceptualRoughnessToRoughness(perceptualRoughness);
// Remap to spec power. See eq. 21 in --> https://dl.dropboxusercontent.com/u/55891920/papers/mm_brdf.pdf
float n = (2.0 / max(FLT_EPSILON, m * m)) - 2.0;

// phi = TWO_PI * (1.0 - u)
// cos(theta) = 1.0 - 2.0 * v
// sin(theta) = sqrt(1.0 - cos^2(theta)) = 2.0 * sqrt(v - v * v)
float phi = TWO_PI - TWO_PI * u;
float cosTheta = 1.0 - 2.0 * v;

正在加载...
取消
保存