浏览代码

HDRenderPipeline: Quix fix about HeightBlend mode v2 for layered material

/main
sebastienlagarde 8 年前
当前提交
e0d3ad66
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 2
      Assets/ScriptableRenderLoop/HDRenderPipeline/Material/LayeredLit/Editor/LayeredLitUI.cs
  2. 2
      Assets/ScriptableRenderLoop/HDRenderPipeline/Material/Lit/LitData.hlsl

2
Assets/ScriptableRenderLoop/HDRenderPipeline/Material/LayeredLit/Editor/LayeredLitUI.cs


if(layerIndex > 0)
{
bool heightBasedBlendEnable = useHeightBasedBlend.floatValue != 0.0f;
bool heightBasedBlendV2Enable = useHeightBasedBlendV2.floatValue != 1.0f;
bool heightBasedBlendV2Enable = useHeightBasedBlendV2.floatValue != 0.0f;
int paramIndex = layerIndex - 1;

2
Assets/ScriptableRenderLoop/HDRenderPipeline/Material/Lit/LitData.hlsl


#endif
float3 minOpaParam = float3(_MinimumOpacity1, _MinimumOpacity2, _MinimumOpacity3);
float3 remapedOpacity = (float3(1.0, 1.0, 1.0) - minOpaParam) * inputAlphaMask.yzw + minOpaParam; // Remap opacity mask from [0..1] to [minOpa..1]
float3 remapedOpacity = lerp(minOpaParam, float3(1.0, 1.0, 1.0), inputAlphaMask.yzw); // Remap opacity mask from [0..1] to [minOpa..1]
float3 opacityAsDensity = saturate((inputAlphaMask.yzw - (float3(1.0, 1.0, 1.0) - inputMaskValues)) * 20.0);
float3 useOpacityAsDensityParam = float3(_OpacityAsDensity1, _OpacityAsDensity2, _OpacityAsDensity3);

正在加载...
取消
保存