AlphaBlendRamp.shader 82 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029
  1. // Made with Amplify Shader Editor
  2. // Available at the Unity Asset Store - http://u3d.as/y3X
  3. Shader "LT/AlphaBlendRamp"
  4. {
  5. Properties
  6. {
  7. [HideInInspector] _AlphaCutoff("Alpha Cutoff ", Range(0, 1)) = 0.5
  8. [HideInInspector] _EmissionColor("Emission Color", Color) = (1,1,1,1)
  9. [ASEBegin]_MainTex("MainTex", 2D) = "white" {}
  10. [HDR]_Color("Color", Color) = (1,1,1,1)
  11. _Intensity("Intensity", Range( 0 , 60)) = 1
  12. _MainTexChannel("通道选择", Vector) = (1,0,0,0)
  13. _MainTexRotation("贴图旋转", Range( 0 , 1)) = 0
  14. _Ramp("Ramp", 2D) = "white" {}
  15. _ca("_ca", Float) = 1
  16. _RampPower("RampPower", Range( 0.2 , 8)) = 0.2
  17. _RampDirection("RampDirection ", Range( 0 , 1)) = 0
  18. _Mask("Mask", 2D) = "white" {}
  19. [ASEEnd]_butouming("butouming", Float) = 1
  20. [HideInInspector] _texcoord( "", 2D ) = "white" {}
  21. [HideInInspector]_QueueOffset("_QueueOffset", Float) = 0
  22. [HideInInspector]_QueueControl("_QueueControl", Float) = -1
  23. [HideInInspector][NoScaleOffset]unity_Lightmaps("unity_Lightmaps", 2DArray) = "" {}
  24. [HideInInspector][NoScaleOffset]unity_LightmapsInd("unity_LightmapsInd", 2DArray) = "" {}
  25. [HideInInspector][NoScaleOffset]unity_ShadowMasks("unity_ShadowMasks", 2DArray) = "" {}
  26. //_TessPhongStrength( "Tess Phong Strength", Range( 0, 1 ) ) = 0.5
  27. //_TessValue( "Tess Max Tessellation", Range( 1, 32 ) ) = 16
  28. //_TessMin( "Tess Min Distance", Float ) = 10
  29. //_TessMax( "Tess Max Distance", Float ) = 25
  30. //_TessEdgeLength ( "Tess Edge length", Range( 2, 50 ) ) = 16
  31. //_TessMaxDisp( "Tess Max Displacement", Float ) = 25
  32. }
  33. SubShader
  34. {
  35. LOD 0
  36. Tags { "RenderPipeline"="UniversalPipeline" "RenderType"="Transparent" "Queue"="Transparent" }
  37. Cull Off
  38. AlphaToMask Off
  39. HLSLINCLUDE
  40. #pragma target 3.0
  41. #pragma prefer_hlslcc gles
  42. #pragma only_renderers d3d9 d3d11 glcore gles gles3 metal vulkan nomrt
  43. #ifndef ASE_TESS_FUNCS
  44. #define ASE_TESS_FUNCS
  45. float4 FixedTess( float tessValue )
  46. {
  47. return tessValue;
  48. }
  49. float CalcDistanceTessFactor (float4 vertex, float minDist, float maxDist, float tess, float4x4 o2w, float3 cameraPos )
  50. {
  51. float3 wpos = mul(o2w,vertex).xyz;
  52. float dist = distance (wpos, cameraPos);
  53. float f = clamp(1.0 - (dist - minDist) / (maxDist - minDist), 0.01, 1.0) * tess;
  54. return f;
  55. }
  56. float4 CalcTriEdgeTessFactors (float3 triVertexFactors)
  57. {
  58. float4 tess;
  59. tess.x = 0.5 * (triVertexFactors.y + triVertexFactors.z);
  60. tess.y = 0.5 * (triVertexFactors.x + triVertexFactors.z);
  61. tess.z = 0.5 * (triVertexFactors.x + triVertexFactors.y);
  62. tess.w = (triVertexFactors.x + triVertexFactors.y + triVertexFactors.z) / 3.0f;
  63. return tess;
  64. }
  65. float CalcEdgeTessFactor (float3 wpos0, float3 wpos1, float edgeLen, float3 cameraPos, float4 scParams )
  66. {
  67. float dist = distance (0.5 * (wpos0+wpos1), cameraPos);
  68. float len = distance(wpos0, wpos1);
  69. float f = max(len * scParams.y / (edgeLen * dist), 1.0);
  70. return f;
  71. }
  72. float DistanceFromPlane (float3 pos, float4 plane)
  73. {
  74. float d = dot (float4(pos,1.0f), plane);
  75. return d;
  76. }
  77. bool WorldViewFrustumCull (float3 wpos0, float3 wpos1, float3 wpos2, float cullEps, float4 planes[6] )
  78. {
  79. float4 planeTest;
  80. planeTest.x = (( DistanceFromPlane(wpos0, planes[0]) > -cullEps) ? 1.0f : 0.0f ) +
  81. (( DistanceFromPlane(wpos1, planes[0]) > -cullEps) ? 1.0f : 0.0f ) +
  82. (( DistanceFromPlane(wpos2, planes[0]) > -cullEps) ? 1.0f : 0.0f );
  83. planeTest.y = (( DistanceFromPlane(wpos0, planes[1]) > -cullEps) ? 1.0f : 0.0f ) +
  84. (( DistanceFromPlane(wpos1, planes[1]) > -cullEps) ? 1.0f : 0.0f ) +
  85. (( DistanceFromPlane(wpos2, planes[1]) > -cullEps) ? 1.0f : 0.0f );
  86. planeTest.z = (( DistanceFromPlane(wpos0, planes[2]) > -cullEps) ? 1.0f : 0.0f ) +
  87. (( DistanceFromPlane(wpos1, planes[2]) > -cullEps) ? 1.0f : 0.0f ) +
  88. (( DistanceFromPlane(wpos2, planes[2]) > -cullEps) ? 1.0f : 0.0f );
  89. planeTest.w = (( DistanceFromPlane(wpos0, planes[3]) > -cullEps) ? 1.0f : 0.0f ) +
  90. (( DistanceFromPlane(wpos1, planes[3]) > -cullEps) ? 1.0f : 0.0f ) +
  91. (( DistanceFromPlane(wpos2, planes[3]) > -cullEps) ? 1.0f : 0.0f );
  92. return !all (planeTest);
  93. }
  94. float4 DistanceBasedTess( float4 v0, float4 v1, float4 v2, float tess, float minDist, float maxDist, float4x4 o2w, float3 cameraPos )
  95. {
  96. float3 f;
  97. f.x = CalcDistanceTessFactor (v0,minDist,maxDist,tess,o2w,cameraPos);
  98. f.y = CalcDistanceTessFactor (v1,minDist,maxDist,tess,o2w,cameraPos);
  99. f.z = CalcDistanceTessFactor (v2,minDist,maxDist,tess,o2w,cameraPos);
  100. return CalcTriEdgeTessFactors (f);
  101. }
  102. float4 EdgeLengthBasedTess( float4 v0, float4 v1, float4 v2, float edgeLength, float4x4 o2w, float3 cameraPos, float4 scParams )
  103. {
  104. float3 pos0 = mul(o2w,v0).xyz;
  105. float3 pos1 = mul(o2w,v1).xyz;
  106. float3 pos2 = mul(o2w,v2).xyz;
  107. float4 tess;
  108. tess.x = CalcEdgeTessFactor (pos1, pos2, edgeLength, cameraPos, scParams);
  109. tess.y = CalcEdgeTessFactor (pos2, pos0, edgeLength, cameraPos, scParams);
  110. tess.z = CalcEdgeTessFactor (pos0, pos1, edgeLength, cameraPos, scParams);
  111. tess.w = (tess.x + tess.y + tess.z) / 3.0f;
  112. return tess;
  113. }
  114. float4 EdgeLengthBasedTessCull( float4 v0, float4 v1, float4 v2, float edgeLength, float maxDisplacement, float4x4 o2w, float3 cameraPos, float4 scParams, float4 planes[6] )
  115. {
  116. float3 pos0 = mul(o2w,v0).xyz;
  117. float3 pos1 = mul(o2w,v1).xyz;
  118. float3 pos2 = mul(o2w,v2).xyz;
  119. float4 tess;
  120. if (WorldViewFrustumCull(pos0, pos1, pos2, maxDisplacement, planes))
  121. {
  122. tess = 0.0f;
  123. }
  124. else
  125. {
  126. tess.x = CalcEdgeTessFactor (pos1, pos2, edgeLength, cameraPos, scParams);
  127. tess.y = CalcEdgeTessFactor (pos2, pos0, edgeLength, cameraPos, scParams);
  128. tess.z = CalcEdgeTessFactor (pos0, pos1, edgeLength, cameraPos, scParams);
  129. tess.w = (tess.x + tess.y + tess.z) / 3.0f;
  130. }
  131. return tess;
  132. }
  133. #endif //ASE_TESS_FUNCS
  134. ENDHLSL
  135. Pass
  136. {
  137. Name "Forward"
  138. Tags { "LightMode"="UniversalForwardOnly" }
  139. Blend SrcAlpha OneMinusSrcAlpha, One OneMinusSrcAlpha
  140. ZWrite Off
  141. ZTest LEqual
  142. Offset 0 , 0
  143. ColorMask RGBA
  144. HLSLPROGRAM
  145. #pragma multi_compile_instancing
  146. #define _RECEIVE_SHADOWS_OFF 1
  147. #define ASE_SRP_VERSION 999999
  148. #pragma multi_compile _ LIGHTMAP_ON
  149. #pragma multi_compile _ DIRLIGHTMAP_COMBINED
  150. #pragma shader_feature _ _SAMPLE_GI
  151. #pragma multi_compile _ _DBUFFER_MRT1 _DBUFFER_MRT2 _DBUFFER_MRT3
  152. #pragma multi_compile _ DEBUG_DISPLAY
  153. #define SHADERPASS SHADERPASS_UNLIT
  154. #pragma vertex vert
  155. #pragma fragment frag
  156. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  157. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Texture.hlsl"
  158. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  159. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  160. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/TextureStack.hlsl"
  161. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  162. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/DBuffer.hlsl"
  163. #include "Packages/com.unity.render-pipelines.universal/Editor/ShaderGraph/Includes/ShaderPass.hlsl"
  164. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Debug/Debugging3D.hlsl"
  165. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Input.hlsl"
  166. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/SurfaceData.hlsl"
  167. #define ASE_NEEDS_FRAG_COLOR
  168. struct VertexInput
  169. {
  170. float4 vertex : POSITION;
  171. float3 ase_normal : NORMAL;
  172. float4 ase_texcoord : TEXCOORD0;
  173. float4 ase_color : COLOR;
  174. UNITY_VERTEX_INPUT_INSTANCE_ID
  175. };
  176. struct VertexOutput
  177. {
  178. float4 clipPos : SV_POSITION;
  179. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  180. float3 worldPos : TEXCOORD0;
  181. #endif
  182. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  183. float4 shadowCoord : TEXCOORD1;
  184. #endif
  185. #ifdef ASE_FOG
  186. float fogFactor : TEXCOORD2;
  187. #endif
  188. float4 ase_texcoord3 : TEXCOORD3;
  189. float4 ase_color : COLOR;
  190. UNITY_VERTEX_INPUT_INSTANCE_ID
  191. UNITY_VERTEX_OUTPUT_STEREO
  192. };
  193. CBUFFER_START(UnityPerMaterial)
  194. float4 _MainTexChannel;
  195. float4 _Mask_ST;
  196. float4 _Color;
  197. float _MainTexRotation;
  198. float _RampDirection;
  199. float _RampPower;
  200. float _Intensity;
  201. float _butouming;
  202. float _ca;
  203. #ifdef TESSELLATION_ON
  204. float _TessPhongStrength;
  205. float _TessValue;
  206. float _TessMin;
  207. float _TessMax;
  208. float _TessEdgeLength;
  209. float _TessMaxDisp;
  210. #endif
  211. CBUFFER_END
  212. sampler2D _Ramp;
  213. sampler2D _MainTex;
  214. sampler2D _Mask;
  215. VertexOutput VertexFunction ( VertexInput v )
  216. {
  217. VertexOutput o = (VertexOutput)0;
  218. UNITY_SETUP_INSTANCE_ID(v);
  219. UNITY_TRANSFER_INSTANCE_ID(v, o);
  220. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  221. o.ase_texcoord3.xy = v.ase_texcoord.xy;
  222. o.ase_color = v.ase_color;
  223. //setting value to unused interpolator channels and avoid initialization warnings
  224. o.ase_texcoord3.zw = 0;
  225. #ifdef ASE_ABSOLUTE_VERTEX_POS
  226. float3 defaultVertexValue = v.vertex.xyz;
  227. #else
  228. float3 defaultVertexValue = float3(0, 0, 0);
  229. #endif
  230. float3 vertexValue = defaultVertexValue;
  231. #ifdef ASE_ABSOLUTE_VERTEX_POS
  232. v.vertex.xyz = vertexValue;
  233. #else
  234. v.vertex.xyz += vertexValue;
  235. #endif
  236. v.ase_normal = v.ase_normal;
  237. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  238. float4 positionCS = TransformWorldToHClip( positionWS );
  239. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  240. o.worldPos = positionWS;
  241. #endif
  242. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  243. VertexPositionInputs vertexInput = (VertexPositionInputs)0;
  244. vertexInput.positionWS = positionWS;
  245. vertexInput.positionCS = positionCS;
  246. o.shadowCoord = GetShadowCoord( vertexInput );
  247. #endif
  248. #ifdef ASE_FOG
  249. o.fogFactor = ComputeFogFactor( positionCS.z );
  250. #endif
  251. o.clipPos = positionCS;
  252. return o;
  253. }
  254. #if defined(TESSELLATION_ON)
  255. struct VertexControl
  256. {
  257. float4 vertex : INTERNALTESSPOS;
  258. float3 ase_normal : NORMAL;
  259. float4 ase_texcoord : TEXCOORD0;
  260. float4 ase_color : COLOR;
  261. UNITY_VERTEX_INPUT_INSTANCE_ID
  262. };
  263. struct TessellationFactors
  264. {
  265. float edge[3] : SV_TessFactor;
  266. float inside : SV_InsideTessFactor;
  267. };
  268. VertexControl vert ( VertexInput v )
  269. {
  270. VertexControl o;
  271. UNITY_SETUP_INSTANCE_ID(v);
  272. UNITY_TRANSFER_INSTANCE_ID(v, o);
  273. o.vertex = v.vertex;
  274. o.ase_normal = v.ase_normal;
  275. o.ase_texcoord = v.ase_texcoord;
  276. o.ase_color = v.ase_color;
  277. return o;
  278. }
  279. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  280. {
  281. TessellationFactors o;
  282. float4 tf = 1;
  283. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  284. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  285. #if defined(ASE_FIXED_TESSELLATION)
  286. tf = FixedTess( tessValue );
  287. #elif defined(ASE_DISTANCE_TESSELLATION)
  288. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  289. #elif defined(ASE_LENGTH_TESSELLATION)
  290. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  291. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  292. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  293. #endif
  294. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  295. return o;
  296. }
  297. [domain("tri")]
  298. [partitioning("fractional_odd")]
  299. [outputtopology("triangle_cw")]
  300. [patchconstantfunc("TessellationFunction")]
  301. [outputcontrolpoints(3)]
  302. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  303. {
  304. return patch[id];
  305. }
  306. [domain("tri")]
  307. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  308. {
  309. VertexInput o = (VertexInput) 0;
  310. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  311. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  312. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  313. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  314. #if defined(ASE_PHONG_TESSELLATION)
  315. float3 pp[3];
  316. for (int i = 0; i < 3; ++i)
  317. 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));
  318. float phongStrength = _TessPhongStrength;
  319. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  320. #endif
  321. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  322. return VertexFunction(o);
  323. }
  324. #else
  325. VertexOutput vert ( VertexInput v )
  326. {
  327. return VertexFunction( v );
  328. }
  329. #endif
  330. half4 frag ( VertexOutput IN ) : SV_Target
  331. {
  332. UNITY_SETUP_INSTANCE_ID( IN );
  333. UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( IN );
  334. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  335. float3 WorldPosition = IN.worldPos;
  336. #endif
  337. float4 ShadowCoords = float4( 0, 0, 0, 0 );
  338. #if defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  339. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR)
  340. ShadowCoords = IN.shadowCoord;
  341. #elif defined(MAIN_LIGHT_CALCULATE_SHADOWS)
  342. ShadowCoords = TransformWorldToShadowCoord( WorldPosition );
  343. #endif
  344. #endif
  345. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  346. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  347. float2 rotator22 = mul( IN.ase_texcoord3.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  348. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  349. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  350. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  351. float2 uv_Mask = IN.ase_texcoord3.xy * _Mask_ST.xy + _Mask_ST.zw;
  352. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  353. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  354. float4 temp_cast_1 = (clampResult38).xxxx;
  355. float4 lerpResult28 = lerp( tex2DNode11 , temp_cast_1 , _RampDirection);
  356. float4 temp_cast_2 = (_RampPower).xxxx;
  357. float2 appendResult43 = (float2(( 1.0 - pow( ( 1.0 - lerpResult28 ) , temp_cast_2 ) ).rg));
  358. float3 BakedAlbedo = 0;
  359. float3 BakedEmission = 0;
  360. float3 Color = ( tex2D( _Ramp, appendResult43 ) * _Intensity * IN.ase_color * _Color ).rgb;
  361. float Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  362. float AlphaClipThreshold = 0.5;
  363. float AlphaClipThresholdShadow = 0.5;
  364. #ifdef _ALPHATEST_ON
  365. clip( Alpha - AlphaClipThreshold );
  366. #endif
  367. #if defined(_DBUFFER)
  368. ApplyDecalToBaseColor(IN.clipPos, Color);
  369. #endif
  370. #if defined(_ALPHAPREMULTIPLY_ON)
  371. Color *= Alpha;
  372. #endif
  373. #ifdef LOD_FADE_CROSSFADE
  374. LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
  375. #endif
  376. #ifdef ASE_FOG
  377. Color = MixFog( Color, IN.fogFactor );
  378. #endif
  379. return half4( Color, Alpha );
  380. }
  381. ENDHLSL
  382. }
  383. Pass
  384. {
  385. Name "DepthOnly"
  386. Tags { "LightMode"="DepthOnly" }
  387. ZWrite On
  388. ColorMask 0
  389. AlphaToMask Off
  390. HLSLPROGRAM
  391. #pragma multi_compile_instancing
  392. #define _RECEIVE_SHADOWS_OFF 1
  393. #define ASE_SRP_VERSION 999999
  394. #pragma vertex vert
  395. #pragma fragment frag
  396. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  397. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  398. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  399. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  400. struct VertexInput
  401. {
  402. float4 vertex : POSITION;
  403. float3 ase_normal : NORMAL;
  404. float4 ase_texcoord : TEXCOORD0;
  405. float4 ase_color : COLOR;
  406. UNITY_VERTEX_INPUT_INSTANCE_ID
  407. };
  408. struct VertexOutput
  409. {
  410. float4 clipPos : SV_POSITION;
  411. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  412. float3 worldPos : TEXCOORD0;
  413. #endif
  414. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  415. float4 shadowCoord : TEXCOORD1;
  416. #endif
  417. float4 ase_texcoord2 : TEXCOORD2;
  418. float4 ase_color : COLOR;
  419. UNITY_VERTEX_INPUT_INSTANCE_ID
  420. UNITY_VERTEX_OUTPUT_STEREO
  421. };
  422. CBUFFER_START(UnityPerMaterial)
  423. float4 _MainTexChannel;
  424. float4 _Mask_ST;
  425. float4 _Color;
  426. float _MainTexRotation;
  427. float _RampDirection;
  428. float _RampPower;
  429. float _Intensity;
  430. float _butouming;
  431. float _ca;
  432. #ifdef TESSELLATION_ON
  433. float _TessPhongStrength;
  434. float _TessValue;
  435. float _TessMin;
  436. float _TessMax;
  437. float _TessEdgeLength;
  438. float _TessMaxDisp;
  439. #endif
  440. CBUFFER_END
  441. sampler2D _MainTex;
  442. sampler2D _Mask;
  443. VertexOutput VertexFunction( VertexInput v )
  444. {
  445. VertexOutput o = (VertexOutput)0;
  446. UNITY_SETUP_INSTANCE_ID(v);
  447. UNITY_TRANSFER_INSTANCE_ID(v, o);
  448. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  449. o.ase_texcoord2.xy = v.ase_texcoord.xy;
  450. o.ase_color = v.ase_color;
  451. //setting value to unused interpolator channels and avoid initialization warnings
  452. o.ase_texcoord2.zw = 0;
  453. #ifdef ASE_ABSOLUTE_VERTEX_POS
  454. float3 defaultVertexValue = v.vertex.xyz;
  455. #else
  456. float3 defaultVertexValue = float3(0, 0, 0);
  457. #endif
  458. float3 vertexValue = defaultVertexValue;
  459. #ifdef ASE_ABSOLUTE_VERTEX_POS
  460. v.vertex.xyz = vertexValue;
  461. #else
  462. v.vertex.xyz += vertexValue;
  463. #endif
  464. v.ase_normal = v.ase_normal;
  465. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  466. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  467. o.worldPos = positionWS;
  468. #endif
  469. o.clipPos = TransformWorldToHClip( positionWS );
  470. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  471. VertexPositionInputs vertexInput = (VertexPositionInputs)0;
  472. vertexInput.positionWS = positionWS;
  473. vertexInput.positionCS = o.clipPos;
  474. o.shadowCoord = GetShadowCoord( vertexInput );
  475. #endif
  476. return o;
  477. }
  478. #if defined(TESSELLATION_ON)
  479. struct VertexControl
  480. {
  481. float4 vertex : INTERNALTESSPOS;
  482. float3 ase_normal : NORMAL;
  483. float4 ase_texcoord : TEXCOORD0;
  484. float4 ase_color : COLOR;
  485. UNITY_VERTEX_INPUT_INSTANCE_ID
  486. };
  487. struct TessellationFactors
  488. {
  489. float edge[3] : SV_TessFactor;
  490. float inside : SV_InsideTessFactor;
  491. };
  492. VertexControl vert ( VertexInput v )
  493. {
  494. VertexControl o;
  495. UNITY_SETUP_INSTANCE_ID(v);
  496. UNITY_TRANSFER_INSTANCE_ID(v, o);
  497. o.vertex = v.vertex;
  498. o.ase_normal = v.ase_normal;
  499. o.ase_texcoord = v.ase_texcoord;
  500. o.ase_color = v.ase_color;
  501. return o;
  502. }
  503. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  504. {
  505. TessellationFactors o;
  506. float4 tf = 1;
  507. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  508. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  509. #if defined(ASE_FIXED_TESSELLATION)
  510. tf = FixedTess( tessValue );
  511. #elif defined(ASE_DISTANCE_TESSELLATION)
  512. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  513. #elif defined(ASE_LENGTH_TESSELLATION)
  514. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  515. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  516. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  517. #endif
  518. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  519. return o;
  520. }
  521. [domain("tri")]
  522. [partitioning("fractional_odd")]
  523. [outputtopology("triangle_cw")]
  524. [patchconstantfunc("TessellationFunction")]
  525. [outputcontrolpoints(3)]
  526. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  527. {
  528. return patch[id];
  529. }
  530. [domain("tri")]
  531. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  532. {
  533. VertexInput o = (VertexInput) 0;
  534. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  535. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  536. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  537. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  538. #if defined(ASE_PHONG_TESSELLATION)
  539. float3 pp[3];
  540. for (int i = 0; i < 3; ++i)
  541. 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));
  542. float phongStrength = _TessPhongStrength;
  543. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  544. #endif
  545. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  546. return VertexFunction(o);
  547. }
  548. #else
  549. VertexOutput vert ( VertexInput v )
  550. {
  551. return VertexFunction( v );
  552. }
  553. #endif
  554. half4 frag(VertexOutput IN ) : SV_TARGET
  555. {
  556. UNITY_SETUP_INSTANCE_ID(IN);
  557. UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( IN );
  558. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  559. float3 WorldPosition = IN.worldPos;
  560. #endif
  561. float4 ShadowCoords = float4( 0, 0, 0, 0 );
  562. #if defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  563. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR)
  564. ShadowCoords = IN.shadowCoord;
  565. #elif defined(MAIN_LIGHT_CALCULATE_SHADOWS)
  566. ShadowCoords = TransformWorldToShadowCoord( WorldPosition );
  567. #endif
  568. #endif
  569. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  570. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  571. float2 rotator22 = mul( IN.ase_texcoord2.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  572. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  573. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  574. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  575. float2 uv_Mask = IN.ase_texcoord2.xy * _Mask_ST.xy + _Mask_ST.zw;
  576. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  577. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  578. float Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  579. float AlphaClipThreshold = 0.5;
  580. #ifdef _ALPHATEST_ON
  581. clip(Alpha - AlphaClipThreshold);
  582. #endif
  583. #ifdef LOD_FADE_CROSSFADE
  584. LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
  585. #endif
  586. return 0;
  587. }
  588. ENDHLSL
  589. }
  590. Pass
  591. {
  592. Name "Universal2D"
  593. Tags { "LightMode"="Universal2D" }
  594. Blend SrcAlpha OneMinusSrcAlpha, One OneMinusSrcAlpha
  595. ZWrite Off
  596. ZTest LEqual
  597. Offset 0 , 0
  598. ColorMask RGBA
  599. HLSLPROGRAM
  600. #pragma multi_compile_instancing
  601. #define _RECEIVE_SHADOWS_OFF 1
  602. #define ASE_SRP_VERSION 999999
  603. #pragma multi_compile _ LIGHTMAP_ON
  604. #pragma multi_compile _ DIRLIGHTMAP_COMBINED
  605. #pragma shader_feature _ _SAMPLE_GI
  606. #pragma multi_compile _ _DBUFFER_MRT1 _DBUFFER_MRT2 _DBUFFER_MRT3
  607. #pragma multi_compile _ DEBUG_DISPLAY
  608. #define SHADERPASS SHADERPASS_UNLIT
  609. #pragma vertex vert
  610. #pragma fragment frag
  611. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  612. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Texture.hlsl"
  613. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  614. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  615. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/TextureStack.hlsl"
  616. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  617. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/DBuffer.hlsl"
  618. #include "Packages/com.unity.render-pipelines.universal/Editor/ShaderGraph/Includes/ShaderPass.hlsl"
  619. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Debug/Debugging3D.hlsl"
  620. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Input.hlsl"
  621. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/SurfaceData.hlsl"
  622. #define ASE_NEEDS_FRAG_COLOR
  623. struct VertexInput
  624. {
  625. float4 vertex : POSITION;
  626. float3 ase_normal : NORMAL;
  627. float4 ase_texcoord : TEXCOORD0;
  628. float4 ase_color : COLOR;
  629. UNITY_VERTEX_INPUT_INSTANCE_ID
  630. };
  631. struct VertexOutput
  632. {
  633. float4 clipPos : SV_POSITION;
  634. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  635. float3 worldPos : TEXCOORD0;
  636. #endif
  637. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  638. float4 shadowCoord : TEXCOORD1;
  639. #endif
  640. #ifdef ASE_FOG
  641. float fogFactor : TEXCOORD2;
  642. #endif
  643. float4 ase_texcoord3 : TEXCOORD3;
  644. float4 ase_color : COLOR;
  645. UNITY_VERTEX_INPUT_INSTANCE_ID
  646. UNITY_VERTEX_OUTPUT_STEREO
  647. };
  648. CBUFFER_START(UnityPerMaterial)
  649. float4 _MainTexChannel;
  650. float4 _Mask_ST;
  651. float4 _Color;
  652. float _MainTexRotation;
  653. float _RampDirection;
  654. float _RampPower;
  655. float _Intensity;
  656. float _butouming;
  657. float _ca;
  658. #ifdef TESSELLATION_ON
  659. float _TessPhongStrength;
  660. float _TessValue;
  661. float _TessMin;
  662. float _TessMax;
  663. float _TessEdgeLength;
  664. float _TessMaxDisp;
  665. #endif
  666. CBUFFER_END
  667. sampler2D _Ramp;
  668. sampler2D _MainTex;
  669. sampler2D _Mask;
  670. VertexOutput VertexFunction ( VertexInput v )
  671. {
  672. VertexOutput o = (VertexOutput)0;
  673. UNITY_SETUP_INSTANCE_ID(v);
  674. UNITY_TRANSFER_INSTANCE_ID(v, o);
  675. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  676. o.ase_texcoord3.xy = v.ase_texcoord.xy;
  677. o.ase_color = v.ase_color;
  678. //setting value to unused interpolator channels and avoid initialization warnings
  679. o.ase_texcoord3.zw = 0;
  680. #ifdef ASE_ABSOLUTE_VERTEX_POS
  681. float3 defaultVertexValue = v.vertex.xyz;
  682. #else
  683. float3 defaultVertexValue = float3(0, 0, 0);
  684. #endif
  685. float3 vertexValue = defaultVertexValue;
  686. #ifdef ASE_ABSOLUTE_VERTEX_POS
  687. v.vertex.xyz = vertexValue;
  688. #else
  689. v.vertex.xyz += vertexValue;
  690. #endif
  691. v.ase_normal = v.ase_normal;
  692. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  693. float4 positionCS = TransformWorldToHClip( positionWS );
  694. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  695. o.worldPos = positionWS;
  696. #endif
  697. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR) && defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  698. VertexPositionInputs vertexInput = (VertexPositionInputs)0;
  699. vertexInput.positionWS = positionWS;
  700. vertexInput.positionCS = positionCS;
  701. o.shadowCoord = GetShadowCoord( vertexInput );
  702. #endif
  703. #ifdef ASE_FOG
  704. o.fogFactor = ComputeFogFactor( positionCS.z );
  705. #endif
  706. o.clipPos = positionCS;
  707. return o;
  708. }
  709. #if defined(TESSELLATION_ON)
  710. struct VertexControl
  711. {
  712. float4 vertex : INTERNALTESSPOS;
  713. float3 ase_normal : NORMAL;
  714. float4 ase_texcoord : TEXCOORD0;
  715. float4 ase_color : COLOR;
  716. UNITY_VERTEX_INPUT_INSTANCE_ID
  717. };
  718. struct TessellationFactors
  719. {
  720. float edge[3] : SV_TessFactor;
  721. float inside : SV_InsideTessFactor;
  722. };
  723. VertexControl vert ( VertexInput v )
  724. {
  725. VertexControl o;
  726. UNITY_SETUP_INSTANCE_ID(v);
  727. UNITY_TRANSFER_INSTANCE_ID(v, o);
  728. o.vertex = v.vertex;
  729. o.ase_normal = v.ase_normal;
  730. o.ase_texcoord = v.ase_texcoord;
  731. o.ase_color = v.ase_color;
  732. return o;
  733. }
  734. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  735. {
  736. TessellationFactors o;
  737. float4 tf = 1;
  738. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  739. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  740. #if defined(ASE_FIXED_TESSELLATION)
  741. tf = FixedTess( tessValue );
  742. #elif defined(ASE_DISTANCE_TESSELLATION)
  743. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  744. #elif defined(ASE_LENGTH_TESSELLATION)
  745. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  746. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  747. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  748. #endif
  749. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  750. return o;
  751. }
  752. [domain("tri")]
  753. [partitioning("fractional_odd")]
  754. [outputtopology("triangle_cw")]
  755. [patchconstantfunc("TessellationFunction")]
  756. [outputcontrolpoints(3)]
  757. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  758. {
  759. return patch[id];
  760. }
  761. [domain("tri")]
  762. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  763. {
  764. VertexInput o = (VertexInput) 0;
  765. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  766. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  767. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  768. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  769. #if defined(ASE_PHONG_TESSELLATION)
  770. float3 pp[3];
  771. for (int i = 0; i < 3; ++i)
  772. 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));
  773. float phongStrength = _TessPhongStrength;
  774. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  775. #endif
  776. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  777. return VertexFunction(o);
  778. }
  779. #else
  780. VertexOutput vert ( VertexInput v )
  781. {
  782. return VertexFunction( v );
  783. }
  784. #endif
  785. half4 frag ( VertexOutput IN ) : SV_Target
  786. {
  787. UNITY_SETUP_INSTANCE_ID( IN );
  788. UNITY_SETUP_STEREO_EYE_INDEX_POST_VERTEX( IN );
  789. #if defined(ASE_NEEDS_FRAG_WORLD_POSITION)
  790. float3 WorldPosition = IN.worldPos;
  791. #endif
  792. float4 ShadowCoords = float4( 0, 0, 0, 0 );
  793. #if defined(ASE_NEEDS_FRAG_SHADOWCOORDS)
  794. #if defined(REQUIRES_VERTEX_SHADOW_COORD_INTERPOLATOR)
  795. ShadowCoords = IN.shadowCoord;
  796. #elif defined(MAIN_LIGHT_CALCULATE_SHADOWS)
  797. ShadowCoords = TransformWorldToShadowCoord( WorldPosition );
  798. #endif
  799. #endif
  800. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  801. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  802. float2 rotator22 = mul( IN.ase_texcoord3.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  803. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  804. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  805. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  806. float2 uv_Mask = IN.ase_texcoord3.xy * _Mask_ST.xy + _Mask_ST.zw;
  807. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  808. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  809. float4 temp_cast_1 = (clampResult38).xxxx;
  810. float4 lerpResult28 = lerp( tex2DNode11 , temp_cast_1 , _RampDirection);
  811. float4 temp_cast_2 = (_RampPower).xxxx;
  812. float2 appendResult43 = (float2(( 1.0 - pow( ( 1.0 - lerpResult28 ) , temp_cast_2 ) ).rg));
  813. float3 BakedAlbedo = 0;
  814. float3 BakedEmission = 0;
  815. float3 Color = ( tex2D( _Ramp, appendResult43 ) * _Intensity * IN.ase_color * _Color ).rgb;
  816. float Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  817. float AlphaClipThreshold = 0.5;
  818. float AlphaClipThresholdShadow = 0.5;
  819. #ifdef _ALPHATEST_ON
  820. clip( Alpha - AlphaClipThreshold );
  821. #endif
  822. #if defined(_DBUFFER)
  823. ApplyDecalToBaseColor(IN.clipPos, Color);
  824. #endif
  825. #if defined(_ALPHAPREMULTIPLY_ON)
  826. Color *= Alpha;
  827. #endif
  828. #ifdef LOD_FADE_CROSSFADE
  829. LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
  830. #endif
  831. #ifdef ASE_FOG
  832. Color = MixFog( Color, IN.fogFactor );
  833. #endif
  834. return half4( Color, Alpha );
  835. }
  836. ENDHLSL
  837. }
  838. Pass
  839. {
  840. Name "SceneSelectionPass"
  841. Tags { "LightMode"="SceneSelectionPass" }
  842. Cull Off
  843. HLSLPROGRAM
  844. #pragma multi_compile_instancing
  845. #define _RECEIVE_SHADOWS_OFF 1
  846. #define ASE_SRP_VERSION 999999
  847. #pragma only_renderers d3d11 glcore gles gles3
  848. #pragma vertex vert
  849. #pragma fragment frag
  850. #define ATTRIBUTES_NEED_NORMAL
  851. #define ATTRIBUTES_NEED_TANGENT
  852. #define SHADERPASS SHADERPASS_DEPTHONLY
  853. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  854. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Texture.hlsl"
  855. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  856. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  857. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/TextureStack.hlsl"
  858. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  859. #include "Packages/com.unity.render-pipelines.universal/Editor/ShaderGraph/Includes/ShaderPass.hlsl"
  860. struct VertexInput
  861. {
  862. float4 vertex : POSITION;
  863. float3 ase_normal : NORMAL;
  864. float4 ase_texcoord : TEXCOORD0;
  865. float4 ase_color : COLOR;
  866. UNITY_VERTEX_INPUT_INSTANCE_ID
  867. };
  868. struct VertexOutput
  869. {
  870. float4 clipPos : SV_POSITION;
  871. float4 ase_texcoord : TEXCOORD0;
  872. float4 ase_color : COLOR;
  873. UNITY_VERTEX_INPUT_INSTANCE_ID
  874. UNITY_VERTEX_OUTPUT_STEREO
  875. };
  876. CBUFFER_START(UnityPerMaterial)
  877. float4 _MainTexChannel;
  878. float4 _Mask_ST;
  879. float4 _Color;
  880. float _MainTexRotation;
  881. float _RampDirection;
  882. float _RampPower;
  883. float _Intensity;
  884. float _butouming;
  885. float _ca;
  886. #ifdef TESSELLATION_ON
  887. float _TessPhongStrength;
  888. float _TessValue;
  889. float _TessMin;
  890. float _TessMax;
  891. float _TessEdgeLength;
  892. float _TessMaxDisp;
  893. #endif
  894. CBUFFER_END
  895. sampler2D _MainTex;
  896. sampler2D _Mask;
  897. int _ObjectId;
  898. int _PassValue;
  899. struct SurfaceDescription
  900. {
  901. float Alpha;
  902. float AlphaClipThreshold;
  903. };
  904. VertexOutput VertexFunction(VertexInput v )
  905. {
  906. VertexOutput o;
  907. ZERO_INITIALIZE(VertexOutput, o);
  908. UNITY_SETUP_INSTANCE_ID(v);
  909. UNITY_TRANSFER_INSTANCE_ID(v, o);
  910. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  911. o.ase_texcoord.xy = v.ase_texcoord.xy;
  912. o.ase_color = v.ase_color;
  913. //setting value to unused interpolator channels and avoid initialization warnings
  914. o.ase_texcoord.zw = 0;
  915. #ifdef ASE_ABSOLUTE_VERTEX_POS
  916. float3 defaultVertexValue = v.vertex.xyz;
  917. #else
  918. float3 defaultVertexValue = float3(0, 0, 0);
  919. #endif
  920. float3 vertexValue = defaultVertexValue;
  921. #ifdef ASE_ABSOLUTE_VERTEX_POS
  922. v.vertex.xyz = vertexValue;
  923. #else
  924. v.vertex.xyz += vertexValue;
  925. #endif
  926. v.ase_normal = v.ase_normal;
  927. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  928. o.clipPos = TransformWorldToHClip(positionWS);
  929. return o;
  930. }
  931. #if defined(TESSELLATION_ON)
  932. struct VertexControl
  933. {
  934. float4 vertex : INTERNALTESSPOS;
  935. float3 ase_normal : NORMAL;
  936. float4 ase_texcoord : TEXCOORD0;
  937. float4 ase_color : COLOR;
  938. UNITY_VERTEX_INPUT_INSTANCE_ID
  939. };
  940. struct TessellationFactors
  941. {
  942. float edge[3] : SV_TessFactor;
  943. float inside : SV_InsideTessFactor;
  944. };
  945. VertexControl vert ( VertexInput v )
  946. {
  947. VertexControl o;
  948. UNITY_SETUP_INSTANCE_ID(v);
  949. UNITY_TRANSFER_INSTANCE_ID(v, o);
  950. o.vertex = v.vertex;
  951. o.ase_normal = v.ase_normal;
  952. o.ase_texcoord = v.ase_texcoord;
  953. o.ase_color = v.ase_color;
  954. return o;
  955. }
  956. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  957. {
  958. TessellationFactors o;
  959. float4 tf = 1;
  960. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  961. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  962. #if defined(ASE_FIXED_TESSELLATION)
  963. tf = FixedTess( tessValue );
  964. #elif defined(ASE_DISTANCE_TESSELLATION)
  965. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  966. #elif defined(ASE_LENGTH_TESSELLATION)
  967. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  968. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  969. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  970. #endif
  971. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  972. return o;
  973. }
  974. [domain("tri")]
  975. [partitioning("fractional_odd")]
  976. [outputtopology("triangle_cw")]
  977. [patchconstantfunc("TessellationFunction")]
  978. [outputcontrolpoints(3)]
  979. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  980. {
  981. return patch[id];
  982. }
  983. [domain("tri")]
  984. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  985. {
  986. VertexInput o = (VertexInput) 0;
  987. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  988. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  989. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  990. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  991. #if defined(ASE_PHONG_TESSELLATION)
  992. float3 pp[3];
  993. for (int i = 0; i < 3; ++i)
  994. 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));
  995. float phongStrength = _TessPhongStrength;
  996. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  997. #endif
  998. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  999. return VertexFunction(o);
  1000. }
  1001. #else
  1002. VertexOutput vert ( VertexInput v )
  1003. {
  1004. return VertexFunction( v );
  1005. }
  1006. #endif
  1007. half4 frag(VertexOutput IN ) : SV_TARGET
  1008. {
  1009. SurfaceDescription surfaceDescription = (SurfaceDescription)0;
  1010. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1011. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1012. float2 rotator22 = mul( IN.ase_texcoord.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  1013. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  1014. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  1015. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  1016. float2 uv_Mask = IN.ase_texcoord.xy * _Mask_ST.xy + _Mask_ST.zw;
  1017. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  1018. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  1019. surfaceDescription.Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  1020. surfaceDescription.AlphaClipThreshold = 0.5;
  1021. #if _ALPHATEST_ON
  1022. float alphaClipThreshold = 0.01f;
  1023. #if ALPHA_CLIP_THRESHOLD
  1024. alphaClipThreshold = surfaceDescription.AlphaClipThreshold;
  1025. #endif
  1026. clip(surfaceDescription.Alpha - alphaClipThreshold);
  1027. #endif
  1028. half4 outColor = half4(_ObjectId, _PassValue, 1.0, 1.0);
  1029. return outColor;
  1030. }
  1031. ENDHLSL
  1032. }
  1033. Pass
  1034. {
  1035. Name "ScenePickingPass"
  1036. Tags { "LightMode"="Picking" }
  1037. HLSLPROGRAM
  1038. #pragma multi_compile_instancing
  1039. #define _RECEIVE_SHADOWS_OFF 1
  1040. #define ASE_SRP_VERSION 999999
  1041. #pragma only_renderers d3d11 glcore gles gles3
  1042. #pragma vertex vert
  1043. #pragma fragment frag
  1044. #define ATTRIBUTES_NEED_NORMAL
  1045. #define ATTRIBUTES_NEED_TANGENT
  1046. #define SHADERPASS SHADERPASS_DEPTHONLY
  1047. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  1048. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Texture.hlsl"
  1049. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  1050. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  1051. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/TextureStack.hlsl"
  1052. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  1053. #include "Packages/com.unity.render-pipelines.universal/Editor/ShaderGraph/Includes/ShaderPass.hlsl"
  1054. struct VertexInput
  1055. {
  1056. float4 vertex : POSITION;
  1057. float3 ase_normal : NORMAL;
  1058. float4 ase_texcoord : TEXCOORD0;
  1059. float4 ase_color : COLOR;
  1060. UNITY_VERTEX_INPUT_INSTANCE_ID
  1061. };
  1062. struct VertexOutput
  1063. {
  1064. float4 clipPos : SV_POSITION;
  1065. float4 ase_texcoord : TEXCOORD0;
  1066. float4 ase_color : COLOR;
  1067. UNITY_VERTEX_INPUT_INSTANCE_ID
  1068. UNITY_VERTEX_OUTPUT_STEREO
  1069. };
  1070. CBUFFER_START(UnityPerMaterial)
  1071. float4 _MainTexChannel;
  1072. float4 _Mask_ST;
  1073. float4 _Color;
  1074. float _MainTexRotation;
  1075. float _RampDirection;
  1076. float _RampPower;
  1077. float _Intensity;
  1078. float _butouming;
  1079. float _ca;
  1080. #ifdef TESSELLATION_ON
  1081. float _TessPhongStrength;
  1082. float _TessValue;
  1083. float _TessMin;
  1084. float _TessMax;
  1085. float _TessEdgeLength;
  1086. float _TessMaxDisp;
  1087. #endif
  1088. CBUFFER_END
  1089. sampler2D _MainTex;
  1090. sampler2D _Mask;
  1091. float4 _SelectionID;
  1092. struct SurfaceDescription
  1093. {
  1094. float Alpha;
  1095. float AlphaClipThreshold;
  1096. };
  1097. VertexOutput VertexFunction(VertexInput v )
  1098. {
  1099. VertexOutput o;
  1100. ZERO_INITIALIZE(VertexOutput, o);
  1101. UNITY_SETUP_INSTANCE_ID(v);
  1102. UNITY_TRANSFER_INSTANCE_ID(v, o);
  1103. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  1104. o.ase_texcoord.xy = v.ase_texcoord.xy;
  1105. o.ase_color = v.ase_color;
  1106. //setting value to unused interpolator channels and avoid initialization warnings
  1107. o.ase_texcoord.zw = 0;
  1108. #ifdef ASE_ABSOLUTE_VERTEX_POS
  1109. float3 defaultVertexValue = v.vertex.xyz;
  1110. #else
  1111. float3 defaultVertexValue = float3(0, 0, 0);
  1112. #endif
  1113. float3 vertexValue = defaultVertexValue;
  1114. #ifdef ASE_ABSOLUTE_VERTEX_POS
  1115. v.vertex.xyz = vertexValue;
  1116. #else
  1117. v.vertex.xyz += vertexValue;
  1118. #endif
  1119. v.ase_normal = v.ase_normal;
  1120. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  1121. o.clipPos = TransformWorldToHClip(positionWS);
  1122. return o;
  1123. }
  1124. #if defined(TESSELLATION_ON)
  1125. struct VertexControl
  1126. {
  1127. float4 vertex : INTERNALTESSPOS;
  1128. float3 ase_normal : NORMAL;
  1129. float4 ase_texcoord : TEXCOORD0;
  1130. float4 ase_color : COLOR;
  1131. UNITY_VERTEX_INPUT_INSTANCE_ID
  1132. };
  1133. struct TessellationFactors
  1134. {
  1135. float edge[3] : SV_TessFactor;
  1136. float inside : SV_InsideTessFactor;
  1137. };
  1138. VertexControl vert ( VertexInput v )
  1139. {
  1140. VertexControl o;
  1141. UNITY_SETUP_INSTANCE_ID(v);
  1142. UNITY_TRANSFER_INSTANCE_ID(v, o);
  1143. o.vertex = v.vertex;
  1144. o.ase_normal = v.ase_normal;
  1145. o.ase_texcoord = v.ase_texcoord;
  1146. o.ase_color = v.ase_color;
  1147. return o;
  1148. }
  1149. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  1150. {
  1151. TessellationFactors o;
  1152. float4 tf = 1;
  1153. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  1154. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  1155. #if defined(ASE_FIXED_TESSELLATION)
  1156. tf = FixedTess( tessValue );
  1157. #elif defined(ASE_DISTANCE_TESSELLATION)
  1158. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  1159. #elif defined(ASE_LENGTH_TESSELLATION)
  1160. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  1161. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  1162. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  1163. #endif
  1164. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  1165. return o;
  1166. }
  1167. [domain("tri")]
  1168. [partitioning("fractional_odd")]
  1169. [outputtopology("triangle_cw")]
  1170. [patchconstantfunc("TessellationFunction")]
  1171. [outputcontrolpoints(3)]
  1172. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  1173. {
  1174. return patch[id];
  1175. }
  1176. [domain("tri")]
  1177. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  1178. {
  1179. VertexInput o = (VertexInput) 0;
  1180. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  1181. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  1182. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  1183. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  1184. #if defined(ASE_PHONG_TESSELLATION)
  1185. float3 pp[3];
  1186. for (int i = 0; i < 3; ++i)
  1187. 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));
  1188. float phongStrength = _TessPhongStrength;
  1189. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  1190. #endif
  1191. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  1192. return VertexFunction(o);
  1193. }
  1194. #else
  1195. VertexOutput vert ( VertexInput v )
  1196. {
  1197. return VertexFunction( v );
  1198. }
  1199. #endif
  1200. half4 frag(VertexOutput IN ) : SV_TARGET
  1201. {
  1202. SurfaceDescription surfaceDescription = (SurfaceDescription)0;
  1203. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1204. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1205. float2 rotator22 = mul( IN.ase_texcoord.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  1206. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  1207. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  1208. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  1209. float2 uv_Mask = IN.ase_texcoord.xy * _Mask_ST.xy + _Mask_ST.zw;
  1210. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  1211. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  1212. surfaceDescription.Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  1213. surfaceDescription.AlphaClipThreshold = 0.5;
  1214. #if _ALPHATEST_ON
  1215. float alphaClipThreshold = 0.01f;
  1216. #if ALPHA_CLIP_THRESHOLD
  1217. alphaClipThreshold = surfaceDescription.AlphaClipThreshold;
  1218. #endif
  1219. clip(surfaceDescription.Alpha - alphaClipThreshold);
  1220. #endif
  1221. half4 outColor = 0;
  1222. outColor = _SelectionID;
  1223. return outColor;
  1224. }
  1225. ENDHLSL
  1226. }
  1227. Pass
  1228. {
  1229. Name "DepthNormals"
  1230. Tags { "LightMode"="DepthNormalsOnly" }
  1231. ZTest LEqual
  1232. ZWrite On
  1233. HLSLPROGRAM
  1234. #pragma multi_compile_instancing
  1235. #define _RECEIVE_SHADOWS_OFF 1
  1236. #define ASE_SRP_VERSION 999999
  1237. #pragma only_renderers d3d11 glcore gles gles3
  1238. #pragma multi_compile_fog
  1239. #pragma instancing_options renderinglayer
  1240. #pragma vertex vert
  1241. #pragma fragment frag
  1242. #define ATTRIBUTES_NEED_NORMAL
  1243. #define ATTRIBUTES_NEED_TANGENT
  1244. #define VARYINGS_NEED_NORMAL_WS
  1245. #define SHADERPASS SHADERPASS_DEPTHNORMALSONLY
  1246. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  1247. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Texture.hlsl"
  1248. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  1249. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  1250. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/TextureStack.hlsl"
  1251. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  1252. #include "Packages/com.unity.render-pipelines.universal/Editor/ShaderGraph/Includes/ShaderPass.hlsl"
  1253. struct VertexInput
  1254. {
  1255. float4 vertex : POSITION;
  1256. float3 ase_normal : NORMAL;
  1257. float4 ase_texcoord : TEXCOORD0;
  1258. float4 ase_color : COLOR;
  1259. UNITY_VERTEX_INPUT_INSTANCE_ID
  1260. };
  1261. struct VertexOutput
  1262. {
  1263. float4 clipPos : SV_POSITION;
  1264. float3 normalWS : TEXCOORD0;
  1265. float4 ase_texcoord1 : TEXCOORD1;
  1266. float4 ase_color : COLOR;
  1267. UNITY_VERTEX_INPUT_INSTANCE_ID
  1268. UNITY_VERTEX_OUTPUT_STEREO
  1269. };
  1270. CBUFFER_START(UnityPerMaterial)
  1271. float4 _MainTexChannel;
  1272. float4 _Mask_ST;
  1273. float4 _Color;
  1274. float _MainTexRotation;
  1275. float _RampDirection;
  1276. float _RampPower;
  1277. float _Intensity;
  1278. float _butouming;
  1279. float _ca;
  1280. #ifdef TESSELLATION_ON
  1281. float _TessPhongStrength;
  1282. float _TessValue;
  1283. float _TessMin;
  1284. float _TessMax;
  1285. float _TessEdgeLength;
  1286. float _TessMaxDisp;
  1287. #endif
  1288. CBUFFER_END
  1289. sampler2D _MainTex;
  1290. sampler2D _Mask;
  1291. struct SurfaceDescription
  1292. {
  1293. float Alpha;
  1294. float AlphaClipThreshold;
  1295. };
  1296. VertexOutput VertexFunction(VertexInput v )
  1297. {
  1298. VertexOutput o;
  1299. ZERO_INITIALIZE(VertexOutput, o);
  1300. UNITY_SETUP_INSTANCE_ID(v);
  1301. UNITY_TRANSFER_INSTANCE_ID(v, o);
  1302. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  1303. o.ase_texcoord1.xy = v.ase_texcoord.xy;
  1304. o.ase_color = v.ase_color;
  1305. //setting value to unused interpolator channels and avoid initialization warnings
  1306. o.ase_texcoord1.zw = 0;
  1307. #ifdef ASE_ABSOLUTE_VERTEX_POS
  1308. float3 defaultVertexValue = v.vertex.xyz;
  1309. #else
  1310. float3 defaultVertexValue = float3(0, 0, 0);
  1311. #endif
  1312. float3 vertexValue = defaultVertexValue;
  1313. #ifdef ASE_ABSOLUTE_VERTEX_POS
  1314. v.vertex.xyz = vertexValue;
  1315. #else
  1316. v.vertex.xyz += vertexValue;
  1317. #endif
  1318. v.ase_normal = v.ase_normal;
  1319. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  1320. float3 normalWS = TransformObjectToWorldNormal(v.ase_normal);
  1321. o.clipPos = TransformWorldToHClip(positionWS);
  1322. o.normalWS.xyz = normalWS;
  1323. return o;
  1324. }
  1325. #if defined(TESSELLATION_ON)
  1326. struct VertexControl
  1327. {
  1328. float4 vertex : INTERNALTESSPOS;
  1329. float3 ase_normal : NORMAL;
  1330. float4 ase_texcoord : TEXCOORD0;
  1331. float4 ase_color : COLOR;
  1332. UNITY_VERTEX_INPUT_INSTANCE_ID
  1333. };
  1334. struct TessellationFactors
  1335. {
  1336. float edge[3] : SV_TessFactor;
  1337. float inside : SV_InsideTessFactor;
  1338. };
  1339. VertexControl vert ( VertexInput v )
  1340. {
  1341. VertexControl o;
  1342. UNITY_SETUP_INSTANCE_ID(v);
  1343. UNITY_TRANSFER_INSTANCE_ID(v, o);
  1344. o.vertex = v.vertex;
  1345. o.ase_normal = v.ase_normal;
  1346. o.ase_texcoord = v.ase_texcoord;
  1347. o.ase_color = v.ase_color;
  1348. return o;
  1349. }
  1350. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  1351. {
  1352. TessellationFactors o;
  1353. float4 tf = 1;
  1354. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  1355. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  1356. #if defined(ASE_FIXED_TESSELLATION)
  1357. tf = FixedTess( tessValue );
  1358. #elif defined(ASE_DISTANCE_TESSELLATION)
  1359. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  1360. #elif defined(ASE_LENGTH_TESSELLATION)
  1361. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  1362. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  1363. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  1364. #endif
  1365. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  1366. return o;
  1367. }
  1368. [domain("tri")]
  1369. [partitioning("fractional_odd")]
  1370. [outputtopology("triangle_cw")]
  1371. [patchconstantfunc("TessellationFunction")]
  1372. [outputcontrolpoints(3)]
  1373. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  1374. {
  1375. return patch[id];
  1376. }
  1377. [domain("tri")]
  1378. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  1379. {
  1380. VertexInput o = (VertexInput) 0;
  1381. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  1382. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  1383. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  1384. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  1385. #if defined(ASE_PHONG_TESSELLATION)
  1386. float3 pp[3];
  1387. for (int i = 0; i < 3; ++i)
  1388. 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));
  1389. float phongStrength = _TessPhongStrength;
  1390. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  1391. #endif
  1392. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  1393. return VertexFunction(o);
  1394. }
  1395. #else
  1396. VertexOutput vert ( VertexInput v )
  1397. {
  1398. return VertexFunction( v );
  1399. }
  1400. #endif
  1401. half4 frag(VertexOutput IN ) : SV_TARGET
  1402. {
  1403. SurfaceDescription surfaceDescription = (SurfaceDescription)0;
  1404. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1405. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1406. float2 rotator22 = mul( IN.ase_texcoord1.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  1407. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  1408. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  1409. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  1410. float2 uv_Mask = IN.ase_texcoord1.xy * _Mask_ST.xy + _Mask_ST.zw;
  1411. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  1412. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  1413. surfaceDescription.Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  1414. surfaceDescription.AlphaClipThreshold = 0.5;
  1415. #if _ALPHATEST_ON
  1416. clip(surfaceDescription.Alpha - surfaceDescription.AlphaClipThreshold);
  1417. #endif
  1418. #ifdef LOD_FADE_CROSSFADE
  1419. LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
  1420. #endif
  1421. float3 normalWS = IN.normalWS;
  1422. return half4(NormalizeNormalPerPixel(normalWS), 0.0);
  1423. }
  1424. ENDHLSL
  1425. }
  1426. Pass
  1427. {
  1428. Name "DepthNormalsOnly"
  1429. Tags { "LightMode"="DepthNormalsOnly" }
  1430. ZTest LEqual
  1431. ZWrite On
  1432. HLSLPROGRAM
  1433. #pragma multi_compile_instancing
  1434. #define _RECEIVE_SHADOWS_OFF 1
  1435. #define ASE_SRP_VERSION 999999
  1436. #pragma exclude_renderers glcore gles gles3
  1437. #pragma vertex vert
  1438. #pragma fragment frag
  1439. #define ATTRIBUTES_NEED_NORMAL
  1440. #define ATTRIBUTES_NEED_TANGENT
  1441. #define ATTRIBUTES_NEED_TEXCOORD1
  1442. #define VARYINGS_NEED_NORMAL_WS
  1443. #define VARYINGS_NEED_TANGENT_WS
  1444. #define SHADERPASS SHADERPASS_DEPTHNORMALSONLY
  1445. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Color.hlsl"
  1446. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/Texture.hlsl"
  1447. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  1448. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Lighting.hlsl"
  1449. #include "Packages/com.unity.render-pipelines.core/ShaderLibrary/TextureStack.hlsl"
  1450. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/ShaderGraphFunctions.hlsl"
  1451. #include "Packages/com.unity.render-pipelines.universal/Editor/ShaderGraph/Includes/ShaderPass.hlsl"
  1452. struct VertexInput
  1453. {
  1454. float4 vertex : POSITION;
  1455. float3 ase_normal : NORMAL;
  1456. float4 ase_texcoord : TEXCOORD0;
  1457. float4 ase_color : COLOR;
  1458. UNITY_VERTEX_INPUT_INSTANCE_ID
  1459. };
  1460. struct VertexOutput
  1461. {
  1462. float4 clipPos : SV_POSITION;
  1463. float3 normalWS : TEXCOORD0;
  1464. float4 ase_texcoord1 : TEXCOORD1;
  1465. float4 ase_color : COLOR;
  1466. UNITY_VERTEX_INPUT_INSTANCE_ID
  1467. UNITY_VERTEX_OUTPUT_STEREO
  1468. };
  1469. CBUFFER_START(UnityPerMaterial)
  1470. float4 _MainTexChannel;
  1471. float4 _Mask_ST;
  1472. float4 _Color;
  1473. float _MainTexRotation;
  1474. float _RampDirection;
  1475. float _RampPower;
  1476. float _Intensity;
  1477. float _butouming;
  1478. float _ca;
  1479. #ifdef TESSELLATION_ON
  1480. float _TessPhongStrength;
  1481. float _TessValue;
  1482. float _TessMin;
  1483. float _TessMax;
  1484. float _TessEdgeLength;
  1485. float _TessMaxDisp;
  1486. #endif
  1487. CBUFFER_END
  1488. sampler2D _MainTex;
  1489. sampler2D _Mask;
  1490. struct SurfaceDescription
  1491. {
  1492. float Alpha;
  1493. float AlphaClipThreshold;
  1494. };
  1495. VertexOutput VertexFunction(VertexInput v )
  1496. {
  1497. VertexOutput o;
  1498. ZERO_INITIALIZE(VertexOutput, o);
  1499. UNITY_SETUP_INSTANCE_ID(v);
  1500. UNITY_TRANSFER_INSTANCE_ID(v, o);
  1501. UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o);
  1502. o.ase_texcoord1.xy = v.ase_texcoord.xy;
  1503. o.ase_color = v.ase_color;
  1504. //setting value to unused interpolator channels and avoid initialization warnings
  1505. o.ase_texcoord1.zw = 0;
  1506. #ifdef ASE_ABSOLUTE_VERTEX_POS
  1507. float3 defaultVertexValue = v.vertex.xyz;
  1508. #else
  1509. float3 defaultVertexValue = float3(0, 0, 0);
  1510. #endif
  1511. float3 vertexValue = defaultVertexValue;
  1512. #ifdef ASE_ABSOLUTE_VERTEX_POS
  1513. v.vertex.xyz = vertexValue;
  1514. #else
  1515. v.vertex.xyz += vertexValue;
  1516. #endif
  1517. v.ase_normal = v.ase_normal;
  1518. float3 positionWS = TransformObjectToWorld( v.vertex.xyz );
  1519. float3 normalWS = TransformObjectToWorldNormal(v.ase_normal);
  1520. o.clipPos = TransformWorldToHClip(positionWS);
  1521. o.normalWS.xyz = normalWS;
  1522. return o;
  1523. }
  1524. #if defined(TESSELLATION_ON)
  1525. struct VertexControl
  1526. {
  1527. float4 vertex : INTERNALTESSPOS;
  1528. float3 ase_normal : NORMAL;
  1529. float4 ase_texcoord : TEXCOORD0;
  1530. float4 ase_color : COLOR;
  1531. UNITY_VERTEX_INPUT_INSTANCE_ID
  1532. };
  1533. struct TessellationFactors
  1534. {
  1535. float edge[3] : SV_TessFactor;
  1536. float inside : SV_InsideTessFactor;
  1537. };
  1538. VertexControl vert ( VertexInput v )
  1539. {
  1540. VertexControl o;
  1541. UNITY_SETUP_INSTANCE_ID(v);
  1542. UNITY_TRANSFER_INSTANCE_ID(v, o);
  1543. o.vertex = v.vertex;
  1544. o.ase_normal = v.ase_normal;
  1545. o.ase_texcoord = v.ase_texcoord;
  1546. o.ase_color = v.ase_color;
  1547. return o;
  1548. }
  1549. TessellationFactors TessellationFunction (InputPatch<VertexControl,3> v)
  1550. {
  1551. TessellationFactors o;
  1552. float4 tf = 1;
  1553. float tessValue = _TessValue; float tessMin = _TessMin; float tessMax = _TessMax;
  1554. float edgeLength = _TessEdgeLength; float tessMaxDisp = _TessMaxDisp;
  1555. #if defined(ASE_FIXED_TESSELLATION)
  1556. tf = FixedTess( tessValue );
  1557. #elif defined(ASE_DISTANCE_TESSELLATION)
  1558. tf = DistanceBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, tessValue, tessMin, tessMax, GetObjectToWorldMatrix(), _WorldSpaceCameraPos );
  1559. #elif defined(ASE_LENGTH_TESSELLATION)
  1560. tf = EdgeLengthBasedTess(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams );
  1561. #elif defined(ASE_LENGTH_CULL_TESSELLATION)
  1562. tf = EdgeLengthBasedTessCull(v[0].vertex, v[1].vertex, v[2].vertex, edgeLength, tessMaxDisp, GetObjectToWorldMatrix(), _WorldSpaceCameraPos, _ScreenParams, unity_CameraWorldClipPlanes );
  1563. #endif
  1564. o.edge[0] = tf.x; o.edge[1] = tf.y; o.edge[2] = tf.z; o.inside = tf.w;
  1565. return o;
  1566. }
  1567. [domain("tri")]
  1568. [partitioning("fractional_odd")]
  1569. [outputtopology("triangle_cw")]
  1570. [patchconstantfunc("TessellationFunction")]
  1571. [outputcontrolpoints(3)]
  1572. VertexControl HullFunction(InputPatch<VertexControl, 3> patch, uint id : SV_OutputControlPointID)
  1573. {
  1574. return patch[id];
  1575. }
  1576. [domain("tri")]
  1577. VertexOutput DomainFunction(TessellationFactors factors, OutputPatch<VertexControl, 3> patch, float3 bary : SV_DomainLocation)
  1578. {
  1579. VertexInput o = (VertexInput) 0;
  1580. o.vertex = patch[0].vertex * bary.x + patch[1].vertex * bary.y + patch[2].vertex * bary.z;
  1581. o.ase_normal = patch[0].ase_normal * bary.x + patch[1].ase_normal * bary.y + patch[2].ase_normal * bary.z;
  1582. o.ase_texcoord = patch[0].ase_texcoord * bary.x + patch[1].ase_texcoord * bary.y + patch[2].ase_texcoord * bary.z;
  1583. o.ase_color = patch[0].ase_color * bary.x + patch[1].ase_color * bary.y + patch[2].ase_color * bary.z;
  1584. #if defined(ASE_PHONG_TESSELLATION)
  1585. float3 pp[3];
  1586. for (int i = 0; i < 3; ++i)
  1587. 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));
  1588. float phongStrength = _TessPhongStrength;
  1589. o.vertex.xyz = phongStrength * (pp[0]*bary.x + pp[1]*bary.y + pp[2]*bary.z) + (1.0f-phongStrength) * o.vertex.xyz;
  1590. #endif
  1591. UNITY_TRANSFER_INSTANCE_ID(patch[0], o);
  1592. return VertexFunction(o);
  1593. }
  1594. #else
  1595. VertexOutput vert ( VertexInput v )
  1596. {
  1597. return VertexFunction( v );
  1598. }
  1599. #endif
  1600. half4 frag(VertexOutput IN ) : SV_TARGET
  1601. {
  1602. SurfaceDescription surfaceDescription = (SurfaceDescription)0;
  1603. float cos22 = cos( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1604. float sin22 = sin( (0.0 + (_MainTexRotation - 0.0) * (( 2.0 * PI ) - 0.0) / (1.0 - 0.0)) );
  1605. float2 rotator22 = mul( IN.ase_texcoord1.xy - float2( 0.5,0.5 ) , float2x2( cos22 , -sin22 , sin22 , cos22 )) + float2( 0.5,0.5 );
  1606. float4 tex2DNode11 = tex2D( _MainTex, rotator22 );
  1607. float4 break19 = ( tex2DNode11 * _MainTexChannel );
  1608. float clampResult21 = clamp( ( break19.r + break19.g + break19.b + break19.a ) , 0.0 , 1.0 );
  1609. float2 uv_Mask = IN.ase_texcoord1.xy * _Mask_ST.xy + _Mask_ST.zw;
  1610. float clampResult36 = clamp( tex2D( _Mask, uv_Mask ).r , 0.0 , 1.0 );
  1611. float clampResult38 = clamp( ( clampResult21 * clampResult36 * IN.ase_color.a ) , 0.0 , 1.0 );
  1612. surfaceDescription.Alpha = ( ( _Color.a * clampResult38 * _butouming ) * _ca );
  1613. surfaceDescription.AlphaClipThreshold = 0.5;
  1614. #if _ALPHATEST_ON
  1615. clip(surfaceDescription.Alpha - surfaceDescription.AlphaClipThreshold);
  1616. #endif
  1617. #ifdef LOD_FADE_CROSSFADE
  1618. LODDitheringTransition( IN.clipPos.xyz, unity_LODFade.x );
  1619. #endif
  1620. float3 normalWS = IN.normalWS;
  1621. return half4(NormalizeNormalPerPixel(normalWS), 0.0);
  1622. }
  1623. ENDHLSL
  1624. }
  1625. }
  1626. CustomEditor "UnityEditor.ShaderGraphUnlitGUI"
  1627. Fallback "Hidden/InternalErrorShader"
  1628. }
  1629. /*ASEBEGIN
  1630. Version=18935
  1631. -43.33325;214;1575.333;798.3334;-535.2097;-334.3815;1.3;True;False
  1632. Node;AmplifyShaderEditor.PiNode;26;-1752.545,26.32182;Inherit;False;1;0;FLOAT;2;False;1;FLOAT;0
  1633. Node;AmplifyShaderEditor.RangedFloatNode;24;-1842.471,-133.7063;Inherit;False;Property;_MainTexRotation;贴图旋转;4;0;Create;False;0;0;0;False;0;False;0;0;0;1;0;1;FLOAT;0
  1634. Node;AmplifyShaderEditor.TexCoordVertexDataNode;23;-1581.544,-356.6783;Inherit;False;0;2;0;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
  1635. Node;AmplifyShaderEditor.TFHCRemapNode;25;-1512.544,-143.6782;Inherit;True;5;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;3;FLOAT;0;False;4;FLOAT;1;False;1;FLOAT;0
  1636. Node;AmplifyShaderEditor.RotatorNode;22;-1226.443,-327.2644;Inherit;True;3;0;FLOAT2;0,0;False;1;FLOAT2;0.5,0.5;False;2;FLOAT;0;False;1;FLOAT2;0
  1637. Node;AmplifyShaderEditor.SamplerNode;11;-927.8995,-396.8804;Inherit;True;Property;_MainTex;MainTex;0;0;Create;True;0;0;0;False;0;False;-1;None;None;True;0;False;white;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
  1638. Node;AmplifyShaderEditor.Vector4Node;17;-874.3092,-98.87162;Inherit;False;Property;_MainTexChannel;通道选择;3;0;Create;False;0;0;0;False;0;False;1,0,0,0;0,0,0,1;0;5;FLOAT4;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
  1639. Node;AmplifyShaderEditor.SimpleMultiplyOpNode;18;-634.3928,-60.52053;Inherit;False;2;2;0;COLOR;0,0,0,0;False;1;FLOAT4;0,0,0,0;False;1;COLOR;0
  1640. Node;AmplifyShaderEditor.BreakToComponentsNode;19;-476.7822,-140.5476;Inherit;False;COLOR;1;0;COLOR;0,0,0,0;False;16;FLOAT;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4;FLOAT;5;FLOAT;6;FLOAT;7;FLOAT;8;FLOAT;9;FLOAT;10;FLOAT;11;FLOAT;12;FLOAT;13;FLOAT;14;FLOAT;15
  1641. Node;AmplifyShaderEditor.CommentaryNode;29;-1162.117,754.5027;Inherit;False;1505.689;534.1698;Comment;5;38;37;36;35;30;不透明;1,1,1,1;0;0
  1642. Node;AmplifyShaderEditor.SamplerNode;30;-1108.28,804.5027;Inherit;True;Property;_Mask;Mask;9;0;Create;True;0;0;0;False;0;False;-1;None;b1a99f53a79a26d478493f52ad2049b6;True;0;False;white;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
  1643. Node;AmplifyShaderEditor.SimpleAddOpNode;20;-295.4679,-141.1914;Inherit;False;4;4;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;0;False;3;FLOAT;0;False;1;FLOAT;0
  1644. Node;AmplifyShaderEditor.VertexColorNode;35;-479.4912,957.1277;Inherit;False;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
  1645. Node;AmplifyShaderEditor.ClampOpNode;21;-143.3259,-136.9677;Inherit;False;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;1;FLOAT;0
  1646. Node;AmplifyShaderEditor.ClampOpNode;36;-748.4,829.2887;Inherit;False;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;1;FLOAT;0
  1647. Node;AmplifyShaderEditor.SimpleMultiplyOpNode;37;-185.863,823.2934;Inherit;True;3;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;0;False;1;FLOAT;0
  1648. Node;AmplifyShaderEditor.ColorNode;15;1238.889,56.22488;Inherit;False;Property;_Color;Color;1;1;[HDR];Create;True;0;0;0;False;0;False;1,1,1,1;0,0,0,0;True;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
  1649. Node;AmplifyShaderEditor.RangedFloatNode;46;1516.234,903.8864;Inherit;False;Property;_butouming;butouming;10;0;Create;True;0;0;0;False;0;False;1;0;0;0;0;1;FLOAT;0
  1650. Node;AmplifyShaderEditor.ClampOpNode;38;113.8619,829.5571;Inherit;False;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;1;False;1;FLOAT;0
  1651. Node;AmplifyShaderEditor.CommentaryNode;45;-99.03671,-690.172;Inherit;False;1665.326;358.451;Comment;8;41;44;43;42;39;28;40;27;ramp;1,1,1,1;0;0
  1652. Node;AmplifyShaderEditor.RangedFloatNode;47;1856.009,907.248;Inherit;False;Property;_ca;_ca;6;0;Create;True;0;0;0;False;0;False;1;1;0;0;0;1;FLOAT;0
  1653. Node;AmplifyShaderEditor.SimpleMultiplyOpNode;16;1725.265,760.9703;Inherit;False;3;3;0;FLOAT;0;False;1;FLOAT;0;False;2;FLOAT;0;False;1;FLOAT;0
  1654. Node;AmplifyShaderEditor.SamplerNode;44;1244.689,-640.172;Inherit;True;Property;_Ramp;Ramp;5;0;Create;True;0;0;0;False;0;False;-1;423e126d2e0def542a062aafca42bca5;b2e6fd8994d94624ca419c336d6dcb96;True;0;False;white;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
  1655. Node;AmplifyShaderEditor.RangedFloatNode;27;-49.03671,-515.582;Inherit;False;Property;_RampDirection;RampDirection ;8;0;Create;True;0;0;0;False;0;False;0;0.513;0;1;0;1;FLOAT;0
  1656. Node;AmplifyShaderEditor.DynamicAppendNode;43;1053.199,-607.4241;Inherit;False;FLOAT2;4;0;FLOAT2;0,0;False;1;FLOAT;0;False;2;FLOAT;0;False;3;FLOAT;0;False;1;FLOAT2;0
  1657. Node;AmplifyShaderEditor.OneMinusNode;42;898.3107,-595.923;Inherit;False;1;0;COLOR;0,0,0,0;False;1;COLOR;0
  1658. Node;AmplifyShaderEditor.OneMinusNode;41;546.1009,-623.3782;Inherit;False;1;0;COLOR;0,0,0,0;False;1;COLOR;0
  1659. Node;AmplifyShaderEditor.RangedFloatNode;13;1307.498,-228.3378;Inherit;False;Property;_Intensity;Intensity;2;0;Create;True;0;0;0;False;0;False;1;0;0;60;0;1;FLOAT;0
  1660. Node;AmplifyShaderEditor.PowerNode;40;735.8746,-610.8766;Inherit;False;False;2;0;COLOR;0,0,0,0;False;1;FLOAT;1;False;1;COLOR;0
  1661. Node;AmplifyShaderEditor.LerpOp;28;321.5584,-578.4473;Inherit;False;3;0;COLOR;0,0,0,0;False;1;COLOR;0,0,0,0;False;2;FLOAT;0;False;1;COLOR;0
  1662. Node;AmplifyShaderEditor.SimpleMultiplyOpNode;48;2010.71,820.1481;Inherit;False;2;2;0;FLOAT;0;False;1;FLOAT;0;False;1;FLOAT;0
  1663. Node;AmplifyShaderEditor.RangedFloatNode;39;463.6391,-422.5836;Inherit;False;Property;_RampPower;RampPower;7;0;Create;True;0;0;0;False;0;False;0.2;3.37;0.2;8;0;1;FLOAT;0
  1664. Node;AmplifyShaderEditor.SimpleMultiplyOpNode;12;1675.673,-173.862;Inherit;False;4;4;0;COLOR;0,0,0,0;False;1;FLOAT;0;False;2;COLOR;0,0,0,0;False;3;COLOR;0,0,0,0;False;1;COLOR;0
  1665. Node;AmplifyShaderEditor.VertexColorNode;14;1089.737,-94.1148;Inherit;False;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
  1666. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;7;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;SceneSelectionPass;0;6;SceneSelectionPass;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;2;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=SceneSelectionPass;False;True;4;d3d11;glcore;gles;gles3;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
  1667. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;5;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;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;2;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
  1668. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;9;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;DepthNormals;0;8;DepthNormals;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;2;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;False;False;False;False;False;False;False;False;False;False;False;False;True;1;False;-1;True;3;False;-1;False;True;1;LightMode=DepthNormalsOnly;False;True;4;d3d11;glcore;gles;gles3;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
  1669. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;8;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;ScenePickingPass;0;7;ScenePickingPass;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;2;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;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;1;LightMode=Picking;False;True;4;d3d11;glcore;gles;gles3;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
  1670. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;2;2111.611,501.4248;Float;False;True;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;LT/AlphaBlendRamp;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;2;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=Transparent=RenderType;Queue=Transparent=Queue=0;True;2;True;8;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;nomrt;0;False;True;1;5;False;-1;10;False;-1;1;1;False;-1;10;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;2;False;-1;True;3;False;-1;True;True;0;False;-1;0;False;-1;True;1;LightMode=UniversalForwardOnly;False;False;0;Hidden/InternalErrorShader;0;0;Standard;22;Surface;1;637800577331334891; Blend;0;637805954579877271;Two Sided;0;637811189211308996;Cast Shadows;0;637800577346088376; Use Shadow Threshold;0;0;Receive Shadows;0;637800577359265521;GPU Instancing;1;0;LOD CrossFade;0;0;Built-in Fog;0;0;DOTS Instancing;0;0;Meta Pass;0;0;Extra Pre Pass;0;0;Tessellation;0;0; Phong;0;0; Strength;0.5,False,-1;0; Type;0;0; Tess;16,False,-1;0; Min;10,False,-1;0; Max;25,False,-1;0; Edge Length;16,False,-1;0; Max Displacement;25,False,-1;0;Vertex Position,InvertActionOnDeselection;1;0;0;10;False;True;False;True;False;True;True;True;True;True;False;;False;0
  1671. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;6;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;Universal2D;0;5;Universal2D;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;2;True;17;d3d9;d3d11;glcore;gles;gles3;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;False;True;1;5;False;-1;10;False;-1;1;1;False;-1;10;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;2;False;-1;True;3;False;-1;True;True;0;False;-1;0;False;-1;True;1;LightMode=Universal2D;False;False;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
  1672. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;4;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;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;2;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
  1673. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;1;1860.229,-74.7038;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;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;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;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
  1674. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;10;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;New Amplify Shader;2992e84f91cbeb14eab234972e07ea9d;True;DepthNormalsOnly;0;9;DepthNormalsOnly;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;2;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;False;False;False;False;False;False;False;False;False;False;False;False;True;1;False;-1;True;3;False;-1;False;True;1;LightMode=DepthNormalsOnly;False;True;15;d3d9;d3d11_9x;d3d11;metal;vulkan;xbox360;xboxone;xboxseries;ps4;playstation;psp2;n3ds;wiiu;switch;nomrt;0;Hidden/InternalErrorShader;0;0;Standard;0;False;0
  1675. Node;AmplifyShaderEditor.TemplateMultiPassMasterNode;3;345,-196;Float;False;False;-1;2;UnityEditor.ShaderGraphUnlitGUI;0;3;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;2;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
  1676. WireConnection;25;0;24;0
  1677. WireConnection;25;4;26;0
  1678. WireConnection;22;0;23;0
  1679. WireConnection;22;2;25;0
  1680. WireConnection;11;1;22;0
  1681. WireConnection;18;0;11;0
  1682. WireConnection;18;1;17;0
  1683. WireConnection;19;0;18;0
  1684. WireConnection;20;0;19;0
  1685. WireConnection;20;1;19;1
  1686. WireConnection;20;2;19;2
  1687. WireConnection;20;3;19;3
  1688. WireConnection;21;0;20;0
  1689. WireConnection;36;0;30;1
  1690. WireConnection;37;0;21;0
  1691. WireConnection;37;1;36;0
  1692. WireConnection;37;2;35;4
  1693. WireConnection;38;0;37;0
  1694. WireConnection;16;0;15;4
  1695. WireConnection;16;1;38;0
  1696. WireConnection;16;2;46;0
  1697. WireConnection;44;1;43;0
  1698. WireConnection;43;0;42;0
  1699. WireConnection;42;0;40;0
  1700. WireConnection;41;0;28;0
  1701. WireConnection;40;0;41;0
  1702. WireConnection;40;1;39;0
  1703. WireConnection;28;0;11;0
  1704. WireConnection;28;1;38;0
  1705. WireConnection;28;2;27;0
  1706. WireConnection;48;0;16;0
  1707. WireConnection;48;1;47;0
  1708. WireConnection;12;0;44;0
  1709. WireConnection;12;1;13;0
  1710. WireConnection;12;2;14;0
  1711. WireConnection;12;3;15;0
  1712. WireConnection;2;2;12;0
  1713. WireConnection;2;3;48;0
  1714. ASEEND*/
  1715. //CHKSM=55F97864E2B646843E9D827D37618D62352054E8