1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096 |
- // Made with Amplify Shader Editor
- // Available at the Unity Asset Store - http://u3d.as/y3X
- Shader "MTE/URP/DisplayNormal/5 Textures"
- {
- Properties
- {
- [HideInInspector] _EmissionColor("Emission Color", Color) = (1,1,1,1)
- [HideInInspector] _AlphaCutoff("Alpha Cutoff ", Range(0, 1)) = 0.5
- [ASEBegin]_Splat0("Layer 1", 2D) = "white" {}
- _Splat1("Layer 2", 2D) = "white" {}
- _Splat2("Layer 3", 2D) = "white" {}
- _Splat3("Layer 4", 2D) = "white" {}
- _Splat4("Layer 5", 2D) = "white" {}
- _Normal0("Normalmap 1", 2D) = "bump" {}
- _Normal1("Normalmap 2", 2D) = "bump" {}
- _Normal2("Normalmap 3", 2D) = "bump" {}
- _Normal3("Normalmap 4", 2D) = "bump" {}
- _Normal4("Normalmap 5", 2D) = "bump" {}
- _Control("Control", 2D) = "white" {}
- _ControlExtra("ControlExtra", 2D) = "white" {}
- _NormalIntensity0("Normal Intensity 1", Range( 0.01 , 10)) = 1
- _NormalIntensity1("Normal Intensity 2", Range( 0.01 , 10)) = 1
- _NormalIntensity2("Normal Intensity 3", Range( 0.01 , 10)) = 1
- _NormalIntensity3("Normal Intensity 4", Range( 0.01 , 10)) = 1
- _NormalIntensity4("Normal Intensity 5", Range( 0.01 , 10)) = 1
- [ASEEnd][Toggle(ENABLE_NORMAL_INTENSITY)] ENABLE_NORMAL_INTENSITY("Normal Intensity", Float) = 1
- //_TessPhongStrength( "Tess Phong Strength", Range( 0, 1 ) ) = 0.5
- //_TessValue( "Tess Max Tessellation", Range( 1, 32 ) ) = 16
- //_TessMin( "Tess Min Distance", Float ) = 10
- //_TessMax( "Tess Max Distance", Float ) = 25
- //_TessEdgeLength ( "Tess Edge length", Range( 2, 50 ) ) = 16
- //_TessMaxDisp( "Tess Max Displacement", Float ) = 25
- }
- SubShader
- {
- LOD 0
-
- Tags { "RenderPipeline"="UniversalPipeline" "RenderType"="Opaque" "Queue"="Geometry" }
-
- Cull Back
- AlphaToMask Off
-
- HLSLINCLUDE
- #pragma target 3.0
- #pragma prefer_hlslcc gles
- #pragma exclude_renderers d3d11_9x
- #ifndef ASE_TESS_FUNCS
- #define ASE_TESS_FUNCS
- float4 FixedTess( float tessValue )
- {
- return tessValue;
- }
-
- float CalcDistanceTessFactor (float4 vertex, float minDist, float maxDist, float tess, float4x4 o2w, float3 cameraPos )
- {
- float3 wpos = mul(o2w,vertex).xyz;
- float dist = distance (wpos, cameraPos);
- float f = clamp(1.0 - (dist - minDist) / (maxDist - minDist), 0.01, 1.0) * tess;
- return f;
- }
- float4 CalcTriEdgeTessFactors (float3 triVertexFactors)
- {
- float4 tess;
- tess.x = 0.5 * (triVertexFactors.y + triVertexFactors.z);
- tess.y = 0.5 * (triVertexFactors.x + triVertexFactors.z);
- tess.z = 0.5 * (triVertexFactors.x + triVertexFactors.y);
- tess.w = (triVertexFactors.x + triVertexFactors.y + triVertexFactors.z) / 3.0f;
- return tess;
- }
- float CalcEdgeTessFactor (float3 wpos0, float3 wpos1, float edgeLen, float3 cameraPos, float4 scParams )
- {
- float dist = distance (0.5 * (wpos0+wpos1), cameraPos);
- float len = distance(wpos0, wpos1);
- float f = max(len * scParams.y / (edgeLen * dist), 1.0);
- return f;
- }
- float DistanceFromPlane (float3 pos, float4 plane)
- {
- float d = dot (float4(pos,1.0f), plane);
- return d;
- }
- bool WorldViewFrustumCull (float3 wpos0, float3 wpos1, float3 wpos2, float cullEps, float4 planes[6] )
- {
- float4 planeTest;
- planeTest.x = (( DistanceFromPlane(wpos0, planes[0]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos1, planes[0]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos2, planes[0]) > -cullEps) ? 1.0f : 0.0f );
- planeTest.y = (( DistanceFromPlane(wpos0, planes[1]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos1, planes[1]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos2, planes[1]) > -cullEps) ? 1.0f : 0.0f );
- planeTest.z = (( DistanceFromPlane(wpos0, planes[2]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos1, planes[2]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos2, planes[2]) > -cullEps) ? 1.0f : 0.0f );
- planeTest.w = (( DistanceFromPlane(wpos0, planes[3]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos1, planes[3]) > -cullEps) ? 1.0f : 0.0f ) +
- (( DistanceFromPlane(wpos2, planes[3]) > -cullEps) ? 1.0f : 0.0f );
- return !all (planeTest);
- }
- float4 DistanceBasedTess( float4 v0, float4 v1, float4 v2, float tess, float minDist, float maxDist, float4x4 o2w, float3 cameraPos )
- {
- float3 f;
- f.x = CalcDistanceTessFactor (v0,minDist,maxDist,tess,o2w,cameraPos);
- f.y = CalcDistanceTessFactor (v1,minDist,maxDist,tess,o2w,cameraPos);
- f.z = CalcDistanceTessFactor (v2,minDist,maxDist,tess,o2w,cameraPos);
- return CalcTriEdgeTessFactors (f);
- }
- float4 EdgeLengthBasedTess( float4 v0, float4 v1, float4 v2, float edgeLength, float4x4 o2w, float3 cameraPos, float4 scParams )
- {
- float3 pos0 = mul(o2w,v0).xyz;
- float3 pos1 = mul(o2w,v1).xyz;
- float3 pos2 = mul(o2w,v2).xyz;
- float4 tess;
- tess.x = CalcEdgeTessFactor (pos1, pos2, edgeLength, cameraPos, scParams);
- tess.y = CalcEdgeTessFactor (pos2, pos0, edgeLength, cameraPos, scParams);
- tess.z = CalcEdgeTessFactor (pos0, pos1, edgeLength, cameraPos, scParams);
- tess.w = (tess.x + tess.y + tess.z) / 3.0f;
- return tess;
- }
- float4 EdgeLengthBasedTessCull( float4 v0, float4 v1, float4 v2, float edgeLength, float maxDisplacement, float4x4 o2w, float3 cameraPos, float4 scParams, float4 planes[6] )
- {
- float3 pos0 = mul(o2w,v0).xyz;
- float3 pos1 = mul(o2w,v1).xyz;
- float3 pos2 = mul(o2w,v2).xyz;
- float4 tess;
- if (WorldViewFrustumCull(pos0, pos1, pos2, maxDisplacement, planes))
- {
- tess = 0.0f;
- }
- else
- {
- tess.x = CalcEdgeTessFactor (pos1, pos2, edgeLength, cameraPos, scParams);
- tess.y = CalcEdgeTessFactor (pos2, pos0, edgeLength, cameraPos, scParams);
- tess.z = CalcEdgeTessFactor (pos0, pos1, edgeLength, cameraPos, scParams);
- tess.w = (tess.x + tess.y + tess.z) / 3.0f;
- }
- return tess;
- }
- #endif //ASE_TESS_FUNCS
- ENDHLSL
-
- Pass
- {
-
- Name "Forward"
- Tags { "LightMode"="UniversalForward" }
-
- Blend One Zero, One Zero
- ZWrite On
- ZTest LEqual
- Offset 0 , 0
- ColorMask RGBA
-
- HLSLPROGRAM
-
- #pragma multi_compile_instancing
- #define ASE_SRP_VERSION 100500
-
- #pragma vertex vert
- #pragma fragment frag
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
- #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
- #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/UnityInstancing.hlsl"
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
- #if ASE_SRP_VERSION <= 70108
- #define REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR
- #endif
- #pragma shader_feature_local ENABLE_NORMAL_INTENSITY
- struct VertexInput
- {
- float4 vertex : POSITION;
- float3 ase_normal : NORMAL;
- float4 ase_texcoord : TEXCOORD0;
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- struct VertexOutput
- {
- float4 clipPos : SV_POSITION;
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- float3 worldPos : TEXCOORD0;
- #endif
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- float4 shadowCoord : TEXCOORD1;
- #endif
- #ifdef ASE_FOG
- float fogFactor : TEXCOORD2;
- #endif
- float4 ase_texcoord3 : TEXCOORD3;
- UNITY_VERTEX_INPUT_INSTANCE_ID
- UNITY_VERTEX_OUTPUT_STEREO
- };
- CBUFFER_START(UnityPerMaterial)
- float4 _Control_ST;
- float4 _ControlExtra_ST;
- float4 _Splat0_ST;
- float4 _Splat1_ST;
- float4 _Splat2_ST;
- float4 _Splat3_ST;
- float4 _Splat4_ST;
- float _NormalIntensity0;
- float _NormalIntensity1;
- float _NormalIntensity2;
- float _NormalIntensity3;
- float _NormalIntensity4;
- #ifdef TESSELLATION_ON
- float _TessPhongStrength;
- float _TessValue;
- float _TessMin;
- float _TessMax;
- float _TessEdgeLength;
- float _TessMaxDisp;
- #endif
- CBUFFER_END
- sampler2D _Control;
- sampler2D _ControlExtra;
- sampler2D _Normal0;
- sampler2D _Splat0;
- sampler2D _Normal1;
- sampler2D _Splat1;
- sampler2D _Normal2;
- sampler2D _Splat2;
- sampler2D _Normal3;
- sampler2D _Splat3;
- sampler2D _Normal4;
- sampler2D _Splat4;
- inline float3 MTE_NormalIntensity_fixed150( float3 Normal, float Strength )
- {
- return lerp(Normal, float3(0,0,1), - Strength + 1.0);
- }
-
- inline float3 MTE_NormalIntensity_fixed152( float3 Normal, float Strength )
- {
- return lerp(Normal, float3(0,0,1), - Strength + 1.0);
- }
-
- inline float3 MTE_NormalIntensity_fixed155( float3 Normal, float Strength )
- {
- return lerp(Normal, float3(0,0,1), - Strength + 1.0);
- }
-
- inline float3 MTE_NormalIntensity_fixed158( float3 Normal, float Strength )
- {
- return lerp(Normal, float3(0,0,1), - Strength + 1.0);
- }
-
- inline float3 MTE_NormalIntensity_fixed161( float3 Normal, float Strength )
- {
- return lerp(Normal, float3(0,0,1), - Strength + 1.0);
- }
-
- float4 WeightedBlend589( half4 Weight, half4 WeightExtra, float4 Layer1, float4 Layer2, float4 Layer3, float4 Layer4, float4 Layer5 )
- {
- return Layer1 * Weight.r + Layer2 * Weight.g + Layer3 * Weight.b + Layer4 * Weight.a + Layer5 * WeightExtra.r;
- }
-
-
- VertexOutput VertexFunction ( VertexInput v )
- {
- VertexOutput o = (VertexOutput)0;
- UNITY_SETUP_INSTANCE_ID(v);
- UNITY_TRANSFER_INSTANCE_ID(v, o);
- UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
- o.ase_texcoord3.xy = v.ase_texcoord.xy;
-
- //setting value to unused interpolator channels and avoid initialization warnings
- o.ase_texcoord3.zw = 0;
- #ifdef ASE_ABSOLUTE_VERTEX_POS
- float3 defaultVertexValue = v.vertex.xyz;
- #else
- float3 defaultVertexValue = float3(0, 0, 0);
- #endif
- float3 vertexValue = defaultVertexValue;
- #ifdef ASE_ABSOLUTE_VERTEX_POS
- v.vertex.xyz = vertexValue;
- #else
- v.vertex.xyz += vertexValue;
- #endif
- v.ase_normal = v.ase_normal;
- float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
- float4 positionCS = TransformWorldToHClip( positionWS );
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- o.worldPos = positionWS;
- #endif
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- VertexPositionInputs vertexInput = (VertexPositionInputs)0;
- vertexInput.positionWS = positionWS;
- vertexInput.positionCS = positionCS;
- o.shadowCoord = GetShadowCoord( vertexInput );
- #endif
- #ifdef ASE_FOG
- o.fogFactor = ComputeFogFactor( positionCS.z );
- #endif
- o.clipPos = positionCS;
- return o;
- }
- #if defined(TESSELLATION_ON)
- struct VertexControl
- {
- float4 vertex : INTERNALTESSPOS;
- float3 ase_normal : NORMAL;
- float4 ase_texcoord : TEXCOORD0;
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- struct TessellationFactors
- {
- float edge[3] : SV_TessFactor;
- float inside : SV_InsideTessFactor;
- };
- VertexControl vert ( VertexInput v )
- {
- VertexControl o;
- UNITY_SETUP_INSTANCE_ID(v);
- UNITY_TRANSFER_INSTANCE_ID(v, o);
- o.vertex = v.vertex;
- o.ase_normal = v.ase_normal;
- o.ase_texcoord = v.ase_texcoord;
- return o;
- }
- TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
- {
- TessellationFactors o;
- float4 tf = 1;
- float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
- float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
- #if defined(ASE_FIXED_TESSELLATION)
- tf = FixedTess( tessValue );
- #elif defined(ASE_DISTANCE_TESSELLATION)
- tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
- #elif defined(ASE_LENGTH_TESSELLATION)
- tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
- #elif defined(ASE_LENGTH_CULL_TESSELLATION)
- tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
- #endif
- o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
- return o;
- }
- [domain("tri")]
- [partitioning("fractional_odd")]
- [outputtopology("triangle_cw")]
- [patchconstantfunc("TessellationFunction")]
- [outputcontrolpoints(3)]
- VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
- {
- return patch[id];
- }
- [domain("tri")]
- VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
- {
- VertexInput o = (VertexInput) 0;
- o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
- o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
- o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
- #if defined(ASE_PHONG_TESSELLATION)
- float3 pp[3];
- for (int i = 0; i < 3; ++i)
- pp[i] = o.vertex.xyz - patch[i].ase_normal * (dot(o.vertex.xyz, patch[i].ase_normal) - dot(patch[i].vertex.xyz, patch[i].ase_normal));
- float phongStrength = _TessPhongStrength;
- o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
- #endif
- UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
- return VertexFunction(o);
- }
- #else
- VertexOutput vert ( VertexInput v )
- {
- return VertexFunction( v );
- }
- #endif
- half4 frag ( VertexOutput IN ) : SV_Target
- {
- UNITY_SETUP_INSTANCE_ID( IN );
- UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( IN );
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- float3 WorldPosition = IN.worldPos;
- #endif
- float4 ShadowCoords = float4( 0, 0, 0, 0 );
- #if defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR)
- ShadowCoords = IN.shadowCoord;
- #elif defined(MAIN_LIGHT_CALCULATE_SHADOWS)
- ShadowCoords = TransformWorldToShadowCoord( WorldPosition );
- #endif
- #endif
- float2 uv_Control = IN.ase_texcoord3.xy * _Control_ST.xy + _Control_ST.zw;
- float4 Weight89 = tex2D( _Control, uv_Control );
- float2 uv_ControlExtra = IN.ase_texcoord3.xy * _ControlExtra_ST.xy + _ControlExtra_ST.zw;
- float4 WeightExtra89 = tex2D( _ControlExtra, uv_ControlExtra );
- float2 uv_Splat0 = IN.ase_texcoord3.xy * _Splat0_ST.xy + _Splat0_ST.zw;
- float3 tex2DNode16 = UnpackNormalScale( tex2D( _Normal0, uv_Splat0 ), 1.0f );
- float3 Normal150 = tex2DNode16;
- float Strength150 = _NormalIntensity0;
- float3 localMTE_NormalIntensity_fixed150 = MTE_NormalIntensity_fixed150( Normal150 , Strength150 );
- #ifdef ENABLE_NORMAL_INTENSITY
- float3 staticSwitch148 = localMTE_NormalIntensity_fixed150;
- #else
- float3 staticSwitch148 = tex2DNode16;
- #endif
- float4 Layer189 = float4( staticSwitch148 , 0.0 );
- float2 uv_Splat1 = IN.ase_texcoord3.xy * _Splat1_ST.xy + _Splat1_ST.zw;
- float3 tex2DNode39 = UnpackNormalScale( tex2D( _Normal1, uv_Splat1 ), 1.0f );
- float3 Normal152 = tex2DNode39;
- float Strength152 = _NormalIntensity1;
- float3 localMTE_NormalIntensity_fixed152 = MTE_NormalIntensity_fixed152( Normal152 , Strength152 );
- #ifdef ENABLE_NORMAL_INTENSITY
- float3 staticSwitch153 = localMTE_NormalIntensity_fixed152;
- #else
- float3 staticSwitch153 = tex2DNode39;
- #endif
- float4 Layer289 = float4( staticSwitch153 , 0.0 );
- float2 uv_Splat2 = IN.ase_texcoord3.xy * _Splat2_ST.xy + _Splat2_ST.zw;
- float3 tex2DNode44 = UnpackNormalScale( tex2D( _Normal2, uv_Splat2 ), 1.0f );
- float3 Normal155 = tex2DNode44;
- float Strength155 = _NormalIntensity2;
- float3 localMTE_NormalIntensity_fixed155 = MTE_NormalIntensity_fixed155( Normal155 , Strength155 );
- #ifdef ENABLE_NORMAL_INTENSITY
- float3 staticSwitch156 = localMTE_NormalIntensity_fixed155;
- #else
- float3 staticSwitch156 = tex2DNode44;
- #endif
- float4 Layer389 = float4( staticSwitch156 , 0.0 );
- float2 uv_Splat3 = IN.ase_texcoord3.xy * _Splat3_ST.xy + _Splat3_ST.zw;
- float3 tex2DNode48 = UnpackNormalScale( tex2D( _Normal3, uv_Splat3 ), 1.0f );
- float3 Normal158 = tex2DNode48;
- float Strength158 = _NormalIntensity3;
- float3 localMTE_NormalIntensity_fixed158 = MTE_NormalIntensity_fixed158( Normal158 , Strength158 );
- #ifdef ENABLE_NORMAL_INTENSITY
- float3 staticSwitch159 = localMTE_NormalIntensity_fixed158;
- #else
- float3 staticSwitch159 = tex2DNode48;
- #endif
- float4 Layer489 = float4( staticSwitch159 , 0.0 );
- float2 uv_Splat4 = IN.ase_texcoord3.xy * _Splat4_ST.xy + _Splat4_ST.zw;
- float3 tex2DNode90 = UnpackNormalScale( tex2D( _Normal4, uv_Splat4 ), 1.0f );
- float3 Normal161 = tex2DNode90;
- float Strength161 = _NormalIntensity4;
- float3 localMTE_NormalIntensity_fixed161 = MTE_NormalIntensity_fixed161( Normal161 , Strength161 );
- #ifdef ENABLE_NORMAL_INTENSITY
- float3 staticSwitch160 = localMTE_NormalIntensity_fixed161;
- #else
- float3 staticSwitch160 = tex2DNode90;
- #endif
- float4 Layer589 = float4( staticSwitch160 , 0.0 );
- float4 localWeightedBlend589 = WeightedBlend589( Weight89 , WeightExtra89 , Layer189 , Layer289 , Layer389 , Layer489 , Layer589 );
-
- float3 BakedAlbedo = 0;
- float3 BakedEmission = 0;
- float3 Color = (localWeightedBlend589*0.5 + 0.5).xyz;
- float Alpha = 1;
- float AlphaClipThreshold = 0.5;
- float AlphaClipThresholdShadow = 0.5;
- #ifdef _ALPHATEST_ON
- clip( Alpha - AlphaClipThreshold );
- #endif
- #ifdef LOD_FADE_CROSSFADE
- LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
- #endif
- #ifdef ASE_FOG
- Color = MixFog( Color, IN.fogFactor );
- #endif
- return half4( Color, Alpha );
- }
- ENDHLSL
- }
-
- Pass
- {
-
- Name "ShadowCaster"
- Tags { "LightMode"="ShadowCaster" }
- ZWrite On
- ZTest LEqual
- AlphaToMask Off
- ColorMask 0
- HLSLPROGRAM
-
- #pragma multi_compile_instancing
- #define ASE_SRP_VERSION 100500
-
- #pragma vertex vert
- #pragma fragment frag
- #if ASE_SRP_VERSION >= 110000
- #pragma multi_compile _ _CASTING_PUNCTUAL_LIGHT_SHADOW
- #endif
- #define SHADERPASS SHADERPASS_SHADOWCASTER
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
- #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
-
- struct VertexInput
- {
- float4 vertex : POSITION;
- float3 ase_normal : NORMAL;
-
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- struct VertexOutput
- {
- float4 clipPos : SV_POSITION;
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- float3 worldPos : TEXCOORD0;
- #endif
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- float4 shadowCoord : TEXCOORD1;
- #endif
-
- UNITY_VERTEX_INPUT_INSTANCE_ID
- UNITY_VERTEX_OUTPUT_STEREO
- };
- CBUFFER_START(UnityPerMaterial)
- float4 _Control_ST;
- float4 _ControlExtra_ST;
- float4 _Splat0_ST;
- float4 _Splat1_ST;
- float4 _Splat2_ST;
- float4 _Splat3_ST;
- float4 _Splat4_ST;
- float _NormalIntensity0;
- float _NormalIntensity1;
- float _NormalIntensity2;
- float _NormalIntensity3;
- float _NormalIntensity4;
- #ifdef TESSELLATION_ON
- float _TessPhongStrength;
- float _TessValue;
- float _TessMin;
- float _TessMax;
- float _TessEdgeLength;
- float _TessMaxDisp;
- #endif
- CBUFFER_END
-
-
- float3 _LightDirection;
- #if ASE_SRP_VERSION >= 110000
- float3 _LightPosition;
- #endif
- VertexOutput VertexFunction( VertexInput v )
- {
- VertexOutput o;
- UNITY_SETUP_INSTANCE_ID(v);
- UNITY_TRANSFER_INSTANCE_ID(v, o);
- UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO( o );
-
- #ifdef ASE_ABSOLUTE_VERTEX_POS
- float3 defaultVertexValue = v.vertex.xyz;
- #else
- float3 defaultVertexValue = float3(0, 0, 0);
- #endif
- float3 vertexValue = defaultVertexValue;
- #ifdef ASE_ABSOLUTE_VERTEX_POS
- v.vertex.xyz = vertexValue;
- #else
- v.vertex.xyz += vertexValue;
- #endif
- v.ase_normal = v.ase_normal;
- float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- o.worldPos = positionWS;
- #endif
- float3 normalWS = TransformObjectToWorldDir( v.ase_normal );
- #if ASE_SRP_VERSION >= 110000
- #if _CASTING_PUNCTUAL_LIGHT_SHADOW
- float3 lightDirectionWS = normalize(_LightPosition - positionWS);
- #else
- float3 lightDirectionWS = _LightDirection;
- #endif
- float4 clipPos = TransformWorldToHClip(ApplyShadowBias(positionWS, normalWS, lightDirectionWS));
- #if UNITY_REVERSED_Z
- clipPos.z = min(clipPos.z, UNITY_NEAR_CLIP_VALUE);
- #else
- clipPos.z = max(clipPos.z, UNITY_NEAR_CLIP_VALUE);
- #endif
- #else
- float4 clipPos = TransformWorldToHClip( ApplyShadowBias( positionWS, normalWS, _LightDirection ) );
- #if UNITY_REVERSED_Z
- clipPos.z = min(clipPos.z, clipPos.w * UNITY_NEAR_CLIP_VALUE);
- #else
- clipPos.z = max(clipPos.z, clipPos.w * UNITY_NEAR_CLIP_VALUE);
- #endif
- #endif
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- VertexPositionInputs vertexInput = (VertexPositionInputs)0;
- vertexInput.positionWS = positionWS;
- vertexInput.positionCS = clipPos;
- o.shadowCoord = GetShadowCoord( vertexInput );
- #endif
- o.clipPos = clipPos;
- return o;
- }
-
- #if defined(TESSELLATION_ON)
- struct VertexControl
- {
- float4 vertex : INTERNALTESSPOS;
- float3 ase_normal : NORMAL;
-
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- struct TessellationFactors
- {
- float edge[3] : SV_TessFactor;
- float inside : SV_InsideTessFactor;
- };
- VertexControl vert ( VertexInput v )
- {
- VertexControl o;
- UNITY_SETUP_INSTANCE_ID(v);
- UNITY_TRANSFER_INSTANCE_ID(v, o);
- o.vertex = v.vertex;
- o.ase_normal = v.ase_normal;
-
- return o;
- }
- TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
- {
- TessellationFactors o;
- float4 tf = 1;
- float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
- float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
- #if defined(ASE_FIXED_TESSELLATION)
- tf = FixedTess( tessValue );
- #elif defined(ASE_DISTANCE_TESSELLATION)
- tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
- #elif defined(ASE_LENGTH_TESSELLATION)
- tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
- #elif defined(ASE_LENGTH_CULL_TESSELLATION)
- tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
- #endif
- o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
- return o;
- }
- [domain("tri")]
- [partitioning("fractional_odd")]
- [outputtopology("triangle_cw")]
- [patchconstantfunc("TessellationFunction")]
- [outputcontrolpoints(3)]
- VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
- {
- return patch[id];
- }
- [domain("tri")]
- VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
- {
- VertexInput o = (VertexInput) 0;
- o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
- o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
-
- #if defined(ASE_PHONG_TESSELLATION)
- float3 pp[3];
- for (int i = 0; i < 3; ++i)
- pp[i] = o.vertex.xyz - patch[i].ase_normal * (dot(o.vertex.xyz, patch[i].ase_normal) - dot(patch[i].vertex.xyz, patch[i].ase_normal));
- float phongStrength = _TessPhongStrength;
- o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
- #endif
- UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
- return VertexFunction(o);
- }
- #else
- VertexOutput vert ( VertexInput v )
- {
- return VertexFunction( v );
- }
- #endif
- half4 frag(VertexOutput IN ) : SV_TARGET
- {
- UNITY_SETUP_INSTANCE_ID( IN );
- UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( IN );
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- float3 WorldPosition = IN.worldPos;
- #endif
- float4 ShadowCoords = float4( 0, 0, 0, 0 );
- #if defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR)
- ShadowCoords = IN.shadowCoord;
- #elif defined(MAIN_LIGHT_CALCULATE_SHADOWS)
- ShadowCoords = TransformWorldToShadowCoord( WorldPosition );
- #endif
- #endif
-
- float Alpha = 1;
- float AlphaClipThreshold = 0.5;
- float AlphaClipThresholdShadow = 0.5;
- #ifdef _ALPHATEST_ON
- #ifdef _ALPHATEST_SHADOW_ON
- clip(Alpha - AlphaClipThresholdShadow);
- #else
- clip(Alpha - AlphaClipThreshold);
- #endif
- #endif
- #ifdef LOD_FADE_CROSSFADE
- LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
- #endif
- return 0;
- }
- ENDHLSL
- }
-
- Pass
- {
-
- Name "DepthOnly"
- Tags { "LightMode"="DepthOnly" }
- ZWrite On
- ColorMask 0
- AlphaToMask Off
- HLSLPROGRAM
-
- #pragma multi_compile_instancing
- #define ASE_SRP_VERSION 100500
-
- #pragma vertex vert
- #pragma fragment frag
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
- #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
- #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
-
- struct VertexInput
- {
- float4 vertex : POSITION;
- float3 ase_normal : NORMAL;
-
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- struct VertexOutput
- {
- float4 clipPos : SV_POSITION;
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- float3 worldPos : TEXCOORD0;
- #endif
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- float4 shadowCoord : TEXCOORD1;
- #endif
-
- UNITY_VERTEX_INPUT_INSTANCE_ID
- UNITY_VERTEX_OUTPUT_STEREO
- };
- CBUFFER_START(UnityPerMaterial)
- float4 _Control_ST;
- float4 _ControlExtra_ST;
- float4 _Splat0_ST;
- float4 _Splat1_ST;
- float4 _Splat2_ST;
- float4 _Splat3_ST;
- float4 _Splat4_ST;
- float _NormalIntensity0;
- float _NormalIntensity1;
- float _NormalIntensity2;
- float _NormalIntensity3;
- float _NormalIntensity4;
- #ifdef TESSELLATION_ON
- float _TessPhongStrength;
- float _TessValue;
- float _TessMin;
- float _TessMax;
- float _TessEdgeLength;
- float _TessMaxDisp;
- #endif
- CBUFFER_END
-
-
- VertexOutput VertexFunction( VertexInput v )
- {
- VertexOutput o = (VertexOutput)0;
- UNITY_SETUP_INSTANCE_ID(v);
- UNITY_TRANSFER_INSTANCE_ID(v, o);
- UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
-
- #ifdef ASE_ABSOLUTE_VERTEX_POS
- float3 defaultVertexValue = v.vertex.xyz;
- #else
- float3 defaultVertexValue = float3(0, 0, 0);
- #endif
- float3 vertexValue = defaultVertexValue;
- #ifdef ASE_ABSOLUTE_VERTEX_POS
- v.vertex.xyz = vertexValue;
- #else
- v.vertex.xyz += vertexValue;
- #endif
- v.ase_normal = v.ase_normal;
- float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- o.worldPos = positionWS;
- #endif
- o.clipPos = TransformWorldToHClip( positionWS );
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- VertexPositionInputs vertexInput = (VertexPositionInputs)0;
- vertexInput.positionWS = positionWS;
- vertexInput.positionCS = o.clipPos;
- o.shadowCoord = GetShadowCoord( vertexInput );
- #endif
- return o;
- }
- #if defined(TESSELLATION_ON)
- struct VertexControl
- {
- float4 vertex : INTERNALTESSPOS;
- float3 ase_normal : NORMAL;
-
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- struct TessellationFactors
- {
- float edge[3] : SV_TessFactor;
- float inside : SV_InsideTessFactor;
- };
- VertexControl vert ( VertexInput v )
- {
- VertexControl o;
- UNITY_SETUP_INSTANCE_ID(v);
- UNITY_TRANSFER_INSTANCE_ID(v, o);
- o.vertex = v.vertex;
- o.ase_normal = v.ase_normal;
-
- return o;
- }
- TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
- {
- TessellationFactors o;
- float4 tf = 1;
- float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
- float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
- #if defined(ASE_FIXED_TESSELLATION)
- tf = FixedTess( tessValue );
- #elif defined(ASE_DISTANCE_TESSELLATION)
- tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
- #elif defined(ASE_LENGTH_TESSELLATION)
- tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
- #elif defined(ASE_LENGTH_CULL_TESSELLATION)
- tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
- #endif
- o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
- return o;
- }
- [domain("tri")]
- [partitioning("fractional_odd")]
- [outputtopology("triangle_cw")]
- [patchconstantfunc("TessellationFunction")]
- [outputcontrolpoints(3)]
- VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
- {
- return patch[id];
- }
- [domain("tri")]
- VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
- {
- VertexInput o = (VertexInput) 0;
- o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
- o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
-
- #if defined(ASE_PHONG_TESSELLATION)
- float3 pp[3];
- for (int i = 0; i < 3; ++i)
- pp[i] = o.vertex.xyz - patch[i].ase_normal * (dot(o.vertex.xyz, patch[i].ase_normal) - dot(patch[i].vertex.xyz, patch[i].ase_normal));
- float phongStrength = _TessPhongStrength;
- o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
- #endif
- UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
- return VertexFunction(o);
- }
- #else
- VertexOutput vert ( VertexInput v )
- {
- return VertexFunction( v );
- }
- #endif
- half4 frag(VertexOutput IN ) : SV_TARGET
- {
- UNITY_SETUP_INSTANCE_ID(IN);
- UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( IN );
- #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
- float3 WorldPosition = IN.worldPos;
- #endif
- float4 ShadowCoords = float4( 0, 0, 0, 0 );
- #if defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
- #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR)
- ShadowCoords = IN.shadowCoord;
- #elif defined(MAIN_LIGHT_CALCULATE_SHADOWS)
- ShadowCoords = TransformWorldToShadowCoord( WorldPosition );
- #endif
- #endif
-
- float Alpha = 1;
- float AlphaClipThreshold = 0.5;
- #ifdef _ALPHATEST_ON
- clip(Alpha - AlphaClipThreshold);
- #endif
- #ifdef LOD_FADE_CROSSFADE
- LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
- #endif
- return 0;
- }
- ENDHLSL
- }
-
- }
-
- CustomEditor "UnityEditor.ShaderGraph.PBRMasterGUI"
- Fallback "Hidden/InternalErrorShader"
-
- }
- /*ASEBEGIN
- Version=18927
- -7;162;1920;857;2287.521;920.1581;2.675784;True;False
- Node;AmplifyShaderEditor.SamplerNode;39;-1091.521,-168.6296;Inherit;True;Property;_Normal1;Normalmap 2;6;0;Create;False;0;0;0;False;0;False;-1;None;None;True;0;True;bump;Auto;True;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;FLOAT3;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.CustomExpressionNode;150;-574.8895,-316.6312;Inherit;False; lerp(Normal, float3(0,0,1), - Strength + 1.0);3;Create;2;True;Normal;FLOAT3;0,0,0;In;;Inherit;False;True;Strength;FLOAT;1;In;;Inherit;False;MTE_NormalIntensity_fixed;True;False;0;;False;2;0;FLOAT3;0,0,0;False;1;FLOAT;1;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.StaticSwitch;160;-244.5296,551.3509;Inherit;False;Property;ENABLE_NORMAL_INTENSITY;Normal Intensity;17;0;Create;False;0;0;0;False;0;False;0;1;1;True;ENABLE_NORMAL_INTENSITY;Toggle;2;Key0;Key1;Create;True;False;9;1;FLOAT3;0,0,0;False;0;FLOAT3;0,0,0;False;2;FLOAT3;0,0,0;False;3;FLOAT3;0,0,0;False;4;FLOAT3;0,0,0;False;5;FLOAT3;0,0,0;False;6;FLOAT3;0,0,0;False;7;FLOAT3;0,0,0;False;8;FLOAT3;0,0,0;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.StaticSwitch;159;-269.1909,331.2658;Inherit;False;Property;ENABLE_NORMAL_INTENSITY;Normal Intensity;25;0;Create;False;0;0;0;False;0;False;0;1;1;True;ENABLE_NORMAL_INTENSITY;Toggle;2;Key0;Key1;Create;True;False;9;1;FLOAT3;0,0,0;False;0;FLOAT3;0,0,0;False;2;FLOAT3;0,0,0;False;3;FLOAT3;0,0,0;False;4;FLOAT3;0,0,0;False;5;FLOAT3;0,0,0;False;6;FLOAT3;0,0,0;False;7;FLOAT3;0,0,0;False;8;FLOAT3;0,0,0;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.TexturePropertyNode;103;-906.9277,-799.4285;Float;True;Property;_Control;Control;10;0;Create;True;0;0;0;False;0;False;None;8de744a27d7e04243b05ab8f3ae22805;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.TexturePropertyNode;106;-909.2297,-614.9675;Float;True;Property;_ControlExtra;ControlExtra;11;0;Create;True;0;0;0;False;0;False;None;adb9d38a84178f04181dddfc906a0eb8;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.TexturePropertyNode;62;-1587.301,596.9885;Float;True;Property;_Splat4;Layer 5;4;0;Create;False;0;0;0;False;0;False;None;None;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.RangedFloatNode;147;-835.6444,-289.7424;Inherit;False;Property;_NormalIntensity0;Normal Intensity 1;12;0;Create;False;0;0;0;False;0;False;1;0;0.01;10;0;1;FLOAT;0
- Node;AmplifyShaderEditor.SamplerNode;6;-405.3592,-796.9125;Inherit;True;Property;_TextureSample4;Texture Sample 4;1;0;Create;True;0;0;0;False;0;False;-1;None;None;True;0;False;black;Auto;False;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.RangedFloatNode;151;-806.9974,-66.04118;Inherit;False;Property;_NormalIntensity1;Normal Intensity 2;13;0;Create;False;0;0;0;False;0;False;1;0;0.01;10;0;1;FLOAT;0
- Node;AmplifyShaderEditor.ScaleAndOffsetNode;172;405.8785,-216.1207;Inherit;False;3;0;FLOAT4;0,0,0,0;False;1;FLOAT;0.5;False;2;FLOAT;0.5;False;1;FLOAT4;0
- Node;AmplifyShaderEditor.TexturePropertyNode;19;-1577.062,-367.0509;Float;True;Property;_Splat0;Layer 1;0;0;Create;False;0;0;0;False;0;False;None;None;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.TextureCoordinatesNode;28;-1335.015,-368.5061;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.TextureCoordinatesNode;105;-658.0287,-549.4305;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.TextureCoordinatesNode;63;-1346.053,586.6523;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.CustomExpressionNode;89;178.7481,-216.4726;Float;False;return Layer1 * Weight.r + Layer2 * Weight.g + Layer3 * Weight.b + Layer4 * Weight.a + Layer5 * WeightExtra.r@;4;Create;7;True;Weight;FLOAT4;0,0,0,0;In;float[5];Half;False;True;WeightExtra;FLOAT4;0,0,0,0;In;;Half;False;True;Layer1;FLOAT4;0,0,0,0;In;;Float;False;True;Layer2;FLOAT4;0,0,0,0;In;;Float;False;True;Layer3;FLOAT4;0,0,0,0;In;;Float;False;True;Layer4;FLOAT4;0,0,0,0;In;;Float;False;True;Layer5;FLOAT4;0,0,0,0;In;;Float;False;Weighted Blend 5;True;False;0;;False;7;0;FLOAT4;0,0,0,0;False;1;FLOAT4;0,0,0,0;False;2;FLOAT4;0,0,0,0;False;3;FLOAT4;0,0,0,0;False;4;FLOAT4;0,0,0,0;False;5;FLOAT4;0,0,0,0;False;6;FLOAT4;0,0,0,0;False;1;FLOAT4;0
- Node;AmplifyShaderEditor.TextureCoordinatesNode;104;-652.7267,-731.8915;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.SamplerNode;86;-398.5552,-612.2275;Inherit;True;Property;_ControlEx;ControlEx;0;0;Create;True;0;0;0;False;0;False;-1;None;None;True;0;False;black;Auto;False;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.CustomExpressionNode;152;-533.2712,-84.67548;Inherit;False; lerp(Normal, float3(0,0,1), - Strength + 1.0);3;Create;2;True;Normal;FLOAT3;0,0,0;In;;Inherit;False;True;Strength;FLOAT;1;In;;Inherit;False;MTE_NormalIntensity_fixed;True;False;0;;False;2;0;FLOAT3;0,0,0;False;1;FLOAT;1;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.StaticSwitch;148;-376.8101,-390.8447;Inherit;False;Property;ENABLE_NORMAL_INTENSITY;Normal Intensity;17;0;Create;False;0;0;0;False;0;False;0;1;1;True;ENABLE_NORMAL_INTENSITY;Toggle;2;Key0;Key1;Create;True;False;9;1;FLOAT3;0,0,0;False;0;FLOAT3;0,0,0;False;2;FLOAT3;0,0,0;False;3;FLOAT3;0,0,0;False;4;FLOAT3;0,0,0;False;5;FLOAT3;0,0,0;False;6;FLOAT3;0,0,0;False;7;FLOAT3;0,0,0;False;8;FLOAT3;0,0,0;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.CustomExpressionNode;158;-475.5244,425.5259;Inherit;False; lerp(Normal, float3(0,0,1), - Strength + 1.0);3;Create;2;True;Normal;FLOAT3;0,0,0;In;;Inherit;False;True;Strength;FLOAT;1;In;;Inherit;False;MTE_NormalIntensity_fixed;True;False;0;;False;2;0;FLOAT3;0,0,0;False;1;FLOAT;1;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.SamplerNode;44;-1073.1,56.93366;Inherit;True;Property;_Normal2;Normalmap 3;7;0;Create;False;0;0;0;False;0;False;-1;None;None;True;0;True;bump;Auto;True;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;FLOAT3;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.CustomExpressionNode;161;-450.8631,645.6109;Inherit;False; lerp(Normal, float3(0,0,1), - Strength + 1.0);3;Create;2;True;Normal;FLOAT3;0,0,0;In;;Inherit;False;True;Strength;FLOAT;1;In;;Inherit;False;MTE_NormalIntensity_fixed;True;False;0;;False;2;0;FLOAT3;0,0,0;False;1;FLOAT;1;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.TexturePropertyNode;41;-1586.853,79.21128;Float;True;Property;_Splat2;Layer 3;2;0;Create;False;0;0;0;False;0;False;None;None;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.TexturePropertyNode;45;-1589.436,346.956;Float;True;Property;_Splat3;Layer 4;3;0;Create;False;0;0;0;False;0;False;None;None;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.TextureCoordinatesNode;42;-1333.14,78.90816;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.TexturePropertyNode;37;-1578.788,-143.0039;Float;True;Property;_Splat1;Layer 2;1;0;Create;False;0;0;0;False;0;False;None;None;False;white;Auto;Texture2D;-1;0;2;SAMPLER2D;0;SAMPLERSTATE;1
- Node;AmplifyShaderEditor.SamplerNode;16;-1110.708,-391.6356;Inherit;True;Property;_Normal0;Normalmap 1;5;0;Create;False;0;0;0;False;0;False;-1;None;None;True;0;True;bump;Auto;True;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;FLOAT3;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.StaticSwitch;153;-326.9375,-163.6058;Inherit;False;Property;ENABLE_NORMAL_INTENSITY;Normal Intensity;17;0;Create;False;0;0;0;False;0;False;0;1;1;True;ENABLE_NORMAL_INTENSITY;Toggle;2;Key0;Key1;Create;True;False;9;1;FLOAT3;0,0,0;False;0;FLOAT3;0,0,0;False;2;FLOAT3;0,0,0;False;3;FLOAT3;0,0,0;False;4;FLOAT3;0,0,0;False;5;FLOAT3;0,0,0;False;6;FLOAT3;0,0,0;False;7;FLOAT3;0,0,0;False;8;FLOAT3;0,0,0;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.RangedFloatNode;157;-749.2515,444.1603;Inherit;False;Property;_NormalIntensity3;Normal Intensity 4;15;0;Create;False;0;0;0;False;0;False;1;0;0.01;10;0;1;FLOAT;0
- Node;AmplifyShaderEditor.TextureCoordinatesNode;46;-1319.638,349.4468;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.RangedFloatNode;162;-724.5905,664.245;Inherit;False;Property;_NormalIntensity4;Normal Intensity 5;16;0;Create;False;0;0;0;False;0;False;1;0;0.01;10;0;1;FLOAT;0
- Node;AmplifyShaderEditor.StaticSwitch;156;-302.5337,59.13985;Inherit;False;Property;ENABLE_NORMAL_INTENSITY;Normal Intensity;15;0;Create;False;0;0;0;False;0;False;0;1;1;True;ENABLE_NORMAL_INTENSITY;Toggle;2;Key0;Key1;Create;True;False;9;1;FLOAT3;0,0,0;False;0;FLOAT3;0,0,0;False;2;FLOAT3;0,0,0;False;3;FLOAT3;0,0,0;False;4;FLOAT3;0,0,0;False;5;FLOAT3;0,0,0;False;6;FLOAT3;0,0,0;False;7;FLOAT3;0,0,0;False;8;FLOAT3;0,0,0;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.CustomExpressionNode;155;-508.8675,152.2203;Inherit;False; lerp(Normal, float3(0,0,1), - Strength + 1.0);3;Create;2;True;Normal;FLOAT3;0,0,0;In;;Inherit;False;True;Strength;FLOAT;1;In;;Inherit;False;MTE_NormalIntensity_fixed;True;False;0;;False;2;0;FLOAT3;0,0,0;False;1;FLOAT;1;False;1;FLOAT3;0
- Node;AmplifyShaderEditor.RangedFloatNode;154;-782.5941,170.8546;Inherit;False;Property;_NormalIntensity2;Normal Intensity 3;14;0;Create;False;0;0;0;False;0;False;1;0;0.01;10;0;1;FLOAT;0
- Node;AmplifyShaderEditor.TextureCoordinatesNode;40;-1337.635,-143.402;Inherit;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.SamplerNode;48;-1053.331,325.686;Inherit;True;Property;_Normal3;Normalmap 4;8;0;Create;False;0;0;0;False;0;False;-1;None;None;True;0;True;bump;Auto;True;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;FLOAT3;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.SamplerNode;90;-1035.083,562.8311;Inherit;True;Property;_Normal4;Normalmap 5;9;0;Create;False;0;0;0;False;0;False;-1;None;None;True;0;True;bump;Auto;True;Object;-1;Auto;Texture2D;8;0;SAMPLER2D;;False;1;FLOAT2;0,0;False;2;FLOAT;0;False;3;FLOAT2;0,0;False;4;FLOAT2;0,0;False;5;FLOAT;1;False;6;FLOAT;0;False;7;SAMPLERSTATE;;False;5;FLOAT3;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;169;683.9721,-229.2669;Float;False;False;-1;2;UnityEditor.ShaderGraph.PBRMasterGUI;0;1;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;DepthOnly;0;3;DepthOnly;0;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;0;False;-1;False;False;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;False;False;False;True;3;RenderPipeline=UniversalPipeline;RenderType=Opaque=RenderType;Queue=Geometry=Queue=0;True;0;True;17;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;False;False;True;False;False;False;False;0;False;-1;False;False;False;False;False;False;False;False;False;True;1;False;-1;False;False;True;1;LightMode=DepthOnly;False;False;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
- Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;166;560.5684,-218.442;Float;False;False;-1;2;UnityEditor.ShaderGraph.PBRMasterGUI;0;1;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;ExtraPrePass;0;0;ExtraPrePass;5;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;0;False;-1;False;False;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;False;False;False;True;3;RenderPipeline=UniversalPipeline;RenderType=Opaque=RenderType;Queue=Geometry=Queue=0;True;0;True;17;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;False;True;1;1;False;-1;0;False;-1;0;1;False;-1;0;False;-1;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;True;True;True;True;0;False;-1;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;True;1;False;-1;True;3;False;-1;True;True;0;False;-1;0;False;-1;True;0;False;False;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
- Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;168;683.9721,-229.2669;Float;False;False;-1;2;UnityEditor.ShaderGraph.PBRMasterGUI;0;1;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;ShadowCaster;0;2;ShadowCaster;0;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;0;False;-1;False;False;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;False;False;False;True;3;RenderPipeline=UniversalPipeline;RenderType=Opaque=RenderType;Queue=Geometry=Queue=0;True;0;True;17;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;False;False;True;False;False;False;False;0;False;-1;False;False;False;False;False;False;False;False;False;True;1;False;-1;True;3;False;-1;False;True;1;LightMode=ShadowCaster;False;False;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
- Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;170;683.9721,-229.2669;Float;False;False;-1;2;UnityEditor.ShaderGraph.PBRMasterGUI;0;1;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;Meta;0;4;Meta;0;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;0;False;-1;False;False;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;False;False;False;True;3;RenderPipeline=UniversalPipeline;RenderType=Opaque=RenderType;Queue=Geometry=Queue=0;True;0;True;17;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;2;False;-1;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;1;LightMode=Meta;False;False;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
- Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;167;595.1331,-216.0233;Float;False;True;-1;2;UnityEditor.ShaderGraph.PBRMasterGUI;0;3;MTE/URP/DisplayNormal/5 Textures;2992e84f91cbeb14eab234972e07ea9d;True;Forward;0;1;Forward;8;False;False;False;False;False;False;False;False;False;False;False;False;True;0;False;-1;False;True;0;False;-1;False;False;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;False;False;False;True;3;RenderPipeline=UniversalPipeline;RenderType=Opaque=RenderType;Queue=Geometry=Queue=0;True;2;True;17;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;False;True;1;1;False;-1;0;False;-1;1;1;False;-1;0;False;-1;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;True;True;True;True;0;False;-1;False;False;False;False;False;False;False;True;False;255;False;-1;255;False;-1;255;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;7;False;-1;1;False;-1;1;False;-1;1;False;-1;False;True;1;False;-1;True;3;False;-1;True;True;0;False;-1;0;False;-1;True;1;LightMode=UniversalForward;False;False;0;Hidden/InternalErrorShader;0;0;Standard;22;Surface;0; Blend;0;Two Sided;1;Cast Shadows;1; Use Shadow Threshold;0;Receive Shadows;1;GPU Instancing;1;LOD CrossFade;0;Built-in Fog;0;DOTS Instancing;0;Meta Pass;0;Extra Pre Pass;0;Tessellation;0; Phong;0; Strength;0.5,False,-1; Type;0; Tess;16,False,-1; Min;10,False,-1; Max;25,False,-1; Edge Length;16,False,-1; Max Displacement;25,False,-1;Vertex Position,InvertActionOnDeselection;1;0;5;False;True;True;True;False;False;;False;0
- WireConnection;39;1;40;0
- WireConnection;150;0;16;0
- WireConnection;150;1;147;0
- WireConnection;160;1;90;0
- WireConnection;160;0;161;0
- WireConnection;159;1;48;0
- WireConnection;159;0;158;0
- WireConnection;6;0;103;0
- WireConnection;6;1;104;0
- WireConnection;172;0;89;0
- WireConnection;28;2;19;0
- WireConnection;105;2;106;0
- WireConnection;63;2;62;0
- WireConnection;89;0;6;0
- WireConnection;89;1;86;0
- WireConnection;89;2;148;0
- WireConnection;89;3;153;0
- WireConnection;89;4;156;0
- WireConnection;89;5;159;0
- WireConnection;89;6;160;0
- WireConnection;104;2;103;0
- WireConnection;86;0;106;0
- WireConnection;86;1;105;0
- WireConnection;152;0;39;0
- WireConnection;152;1;151;0
- WireConnection;148;1;16;0
- WireConnection;148;0;150;0
- WireConnection;158;0;48;0
- WireConnection;158;1;157;0
- WireConnection;44;1;42;0
- WireConnection;161;0;90;0
- WireConnection;161;1;162;0
- WireConnection;42;2;41;0
- WireConnection;16;1;28;0
- WireConnection;153;1;39;0
- WireConnection;153;0;152;0
- WireConnection;46;2;45;0
- WireConnection;156;1;44;0
- WireConnection;156;0;155;0
- WireConnection;155;0;44;0
- WireConnection;155;1;154;0
- WireConnection;40;2;37;0
- WireConnection;48;1;46;0
- WireConnection;90;1;63;0
- WireConnection;167;2;172;0
- ASEEND*/
- //CHKSM=9415E272EBB9646AAC23E8A951AC791919245EF8
|