浏览代码

Fixed multipliers on LayeredLit for Smoothness, Metallic and Anisotropy (were always 0 before).

/main
Julien Ignace 8 年前
当前提交
d4e1f7c7
共有 10 个文件被更改,包括 21 次插入16 次删除
  1. 6
      Assets/ScriptableRenderLoop/HDRenderLoop/Material/Lit/LitSurfaceData.hlsl
  2. 2
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Detail_Checker.tga
  3. 6
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_BlendColor.mat
  4. 2
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_BlendColor.mat.meta
  5. 3
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_Layer3_Triplanar.mat
  6. 2
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_Layer3_Triplanar.mat.meta
  7. 5
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_Blue.mat
  8. 3
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_Green.mat
  9. 5
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_Red.mat
  10. 3
      Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_White.mat

6
Assets/ScriptableRenderLoop/HDRenderLoop/Material/Lit/LitSurfaceData.hlsl


#else
surfaceData.perceptualSmoothness = 1.0;
#endif
surfaceData.perceptualSmoothness *= _Smoothness;
surfaceData.perceptualSmoothness = ADD_IDX(_Smoothness);
#ifdef _DETAIL_MAP
surfaceData.perceptualSmoothness *= LerpWhiteTo(2.0 * saturate(detailSmoothness * ADD_IDX(_DetailSmoothnessScale)), detailMask);
#endif

surfaceData.metallic = 1.0;
surfaceData.ambientOcclusion = 1.0;
#endif
surfaceData.metallic *= _Metallic;
surfaceData.metallic *= ADD_IDX(_Metallic);
// This part of the code is not used in case of layered shader but we keep the same macro system for simplicity
#if !defined(LAYERED_LIT_SHADER)

#else
surfaceData.anisotropy = 1.0;
#endif
surfaceData.anisotropy *= _Anisotropy;
surfaceData.anisotropy *= ADD_IDX(_Anisotropy);
surfaceData.specular = 0.04;

2
Assets/TestScenes/HDTest/LayeredLitTest/Material/Detail_Checker.tga
文件差异内容过多而无法显示
查看文件

6
Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_BlendColor.mat


_DISTORTIONONLY_OFF _EMISSION _EMISSIVE_COLOR _LAYEREDLIT_4_LAYER _LAYEREDLIT_4_LAYERS
_LAYERMASKMAP _LAYER_MAPPING_PLANAR0 _LAYER_MAPPING_PLANAR_0 _LAYER_MAPPING_PLANAR_1
_LAYER_MAPPING_PLANAR_2 _LAYER_MAPPING_PLANAR_3 _LAYER_MASK_VERTEX_COLOR _NORMALMAP_TANGENT_SPACE
_REQUIRE_UV3
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:

- _Parallax: 0.02
- _Smoothness: 0.5
- _Smoothness0: 0.5
- _Smoothness1: 0.5
- _Smoothness1: 0.2
- _Smoothness3: 0.5
- _Smoothness3: 0.4
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1

2
Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_BlendColor.mat.meta


fileFormatVersion: 2
guid: f5e011eaf3efd6a418f211803a5f7d74
timeCreated: 1480682649
timeCreated: 1480943223
licenseType: Pro
NativeFormatImporter:
userData: '{"GUIDArray":["fbea672215bd9944f8d9f98d5437e3cb","b91619c97bb14b64b82c0cdeaac0cc68","be6f395f0458348419faf76aca4cf856","000d0f1d5b188ed43a674de93e854997"]}'

3
Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_Layer3_Triplanar.mat


m_Shader: {fileID: 4800000, guid: 81d02e8644315b742b154842a3a2f98c, type: 3}
m_ShaderKeywords: _ALPHACUTOFFENABLE_OFF _DETAIL_MAP _DETAIL_MAP_WITH_NORMAL _DISTORTIONDEPTHTEST_OFF
_DISTORTIONONLY_OFF _EMISSION _EMISSIVE_COLOR _LAYEREDLIT_4_LAYERS _LAYER_MAPPING_TRIPLANAR_3
_LAYER_MASK_VERTEX_COLOR _NORMALMAP_TANGENT_SPACE _REQUIRE_UV3
_LAYER_MASK_VERTEX_COLOR _NORMALMAP_TANGENT_SPACE
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:

2
Assets/TestScenes/HDTest/LayeredLitTest/Material/Layered_Layer3_Triplanar.mat.meta


fileFormatVersion: 2
guid: 0284c7765797bfe42b104f08550600a8
timeCreated: 1480681151
timeCreated: 1480935617
licenseType: Pro
NativeFormatImporter:
userData: '{"GUIDArray":["686eb5593c0e94f4eb86ca1d3cfef7fa","686eb5593c0e94f4eb86ca1d3cfef7fa","686eb5593c0e94f4eb86ca1d3cfef7fa","6c40a6ba55a62fc4c92fdc1cdee2f85a"]}'

5
Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_Blue.mat


m_Name: Lit_Blue
m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3}
m_ShaderKeywords: _ALPHACUTOFFENABLE_OFF _DETAIL_MAP_WITH_NORMAL _DISTORTIONDEPTHTEST_OFF
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE _REQUIRE_UV3
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:

- _NormalMapSpace: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _Smoothness: 0.5
- _Smoothness: 0.4
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1

3
Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_Green.mat


m_Name: Lit_Green
m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3}
m_ShaderKeywords: _ALPHACUTOFFENABLE_OFF _DETAIL_MAP_WITH_NORMAL _DISTORTIONDEPTHTEST_OFF
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE _REQUIRE_UV3
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:

5
Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_Red.mat


m_Name: Lit_Red
m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3}
m_ShaderKeywords: _ALPHACUTOFFENABLE_OFF _DETAIL_MAP_WITH_NORMAL _DISTORTIONDEPTHTEST_OFF
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE _REQUIRE_UV3
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:

- _NormalMapSpace: 0
- _OcclusionStrength: 1
- _Parallax: 0.02
- _Smoothness: 0.5
- _Smoothness: 0.2
- _SmoothnessTextureChannel: 0
- _SpecularHighlights: 1
- _SrcBlend: 1

3
Assets/TestScenes/HDTest/LayeredLitTest/Material/Lit_White.mat


m_Name: Lit_White
m_Shader: {fileID: 4800000, guid: 6e4ae4064600d784cac1e41a9e6f2e59, type: 3}
m_ShaderKeywords: _ALPHACUTOFFENABLE_OFF _DETAIL_MAP_WITH_NORMAL _DISTORTIONDEPTHTEST_OFF
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE _REQUIRE_UV3
_DISTORTIONONLY_OFF _EMISSION _NORMALMAP_TANGENT_SPACE
disabledShaderPasses: []
m_SavedProperties:
serializedVersion: 3
m_TexEnvs:

正在加载...
取消
保存