浏览代码

HDRenderLoop: Rename TEXTURE2D_PASS to TEXTURE2D_PARAM

/main
sebastienlagarde 8 年前
当前提交
fc554180
共有 2 个文件被更改,包括 15 次插入15 次删除
  1. 14
      Assets/ScriptableRenderLoop/HDRenderLoop/Shaders/Material/Lit/LitData.hlsl
  2. 16
      Assets/ScriptableRenderLoop/ShaderLibrary/API/D3D11.hlsl

14
Assets/ScriptableRenderLoop/HDRenderLoop/Shaders/Material/Lit/LitData.hlsl


WorldToTexture = mul(mul(scale, translation), WorldToTexture);
return SampleProbeVolumeSH4(TEXTURE3D_PASS(unity_ProbeVolumeSH, samplerunity_ProbeVolumeSH), positionWS, normalWS, WorldToTexture, unity_ProbeVolumeParams.z);
return SampleProbeVolumeSH4(TEXTURE3D_PARAM(unity_ProbeVolumeSH, samplerunity_ProbeVolumeSH), positionWS, normalWS, WorldToTexture, unity_ProbeVolumeParams.z);
}
#else

#ifdef LIGHTMAP_ON
#ifdef DIRLIGHTMAP_COMBINED
bakeDiffuseLighting += SampleDirectionalLightmap(TEXTURE2D_PASS(unity_Lightmap, samplerunity_Lightmap),
TEXTURE2D_PASS(unity_LightmapInd, samplerunity_Lightmap),
bakeDiffuseLighting += SampleDirectionalLightmap(TEXTURE2D_PARAM(unity_Lightmap, samplerunity_Lightmap),
TEXTURE2D_PARAM(unity_LightmapInd, samplerunity_Lightmap),
bakeDiffuseLighting += SampleSingleLightmap(TEXTURE2D_PASS(unity_Lightmap, samplerunity_Lightmap), uvStaticLightmap, unity_LightmapST);
bakeDiffuseLighting += SampleSingleLightmap(TEXTURE2D_PARAM(unity_Lightmap, samplerunity_Lightmap), uvStaticLightmap, unity_LightmapST);
bakeDiffuseLighting += SampleDirectionalLightmap(TEXTURE2D_PASS(unity_DynamicLightmap, samplerunity_DynamicLightmap),
TEXTURE2D_PASS(unity_DynamicDirectionality, samplerunity_DynamicLightmap),
bakeDiffuseLighting += SampleDirectionalLightmap(TEXTURE2D_PARAM(unity_DynamicLightmap, samplerunity_DynamicLightmap),
TEXTURE2D_PARAM(unity_DynamicDirectionality, samplerunity_DynamicLightmap),
bakeDiffuseLighting += SampleSingleLightmap(TEXTURE2D_PASS(unity_DynamicLightmap, samplerunity_DynamicLightmap), uvDynamicLightmap, unity_DynamicLightmapST);
bakeDiffuseLighting += SampleSingleLightmap(TEXTURE2D_PARAM(unity_DynamicLightmap, samplerunity_DynamicLightmap), uvDynamicLightmap, unity_DynamicLightmapST);
#endif
#endif

16
Assets/ScriptableRenderLoop/ShaderLibrary/API/D3D11.hlsl


#define TEXTURE2D_ARRAY_SHADOW_ARGS(textureName, samplerName) Texture2DArray textureName, SamplerComparisonState samplerName
#define TEXTURECUBE_SHADOW_ARGS(textureName, samplerName) TextureCube textureName, SamplerComparisonState samplerName
#define TEXTURE2D_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_ARRAY_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURECUBE_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURECUBE_ARRAY_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURE3D_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_SHADOW_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_ARRAY_SHADOW_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURECUBE_SHADOW_PASS(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_ARRAY_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURECUBE_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURECUBE_ARRAY_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURE3D_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_SHADOW_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURE2D_ARRAY_SHADOW_PARAM(textureName, samplerName) textureName, samplerName
#define TEXTURECUBE_SHADOW_PARAM(textureName, samplerName) textureName, samplerName
#define SAMPLE_TEXTURE2D(textureName, samplerName, coord2) textureName.Sample(samplerName, coord2)
#define SAMPLE_TEXTURE2D_LOD(textureName, samplerName, coord2, lod) textureName.SampleLevel(samplerName, coord2, lod)

正在加载...
取消
保存