123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166 |
- // Made with Amplify Shader Editor
- // Available at the Unity Asset Store - http://u3d.as/y3X
- Shader "New Amplify Shader"
- {
- Properties
- {
- _TextureSample0("Texture Sample 0", 2D) = "white" {}
- _TextureSample1("Texture Sample 1", 2D) = "white" {}
- _Color0("Color 0", Color) = (0,0,0,0)
- _Vector0("Vector 0", Vector) = (0,0,0,0)
- _Vector1("Vector 1", Vector) = (0,0,0,0)
- _F("F", Float) = 0.93
- [HideInInspector] _texcoord( "", 2D ) = "white" {}
- [HideInInspector] __dirty( "", Int ) = 1
- }
- SubShader
- {
- Tags{ "RenderType" = "Opaque" "Queue" = "Geometry+0" "IsEmissive" = "true" }
- Cull Back
- CGINCLUDE
- #include "UnityShaderVariables.cginc"
- #include "UnityPBSLighting.cginc"
- #include "Lighting.cginc"
- #pragma target 3.0
- struct Input
- {
- float2 uv_texcoord;
- float3 worldPos;
- float3 worldNormal;
- };
- uniform sampler2D _TextureSample0;
- uniform float2 _Vector1;
- uniform sampler2D _TextureSample1;
- uniform float2 _Vector0;
- uniform float _F;
- uniform float4 _Color0;
- void surf( Input i , inout SurfaceOutputStandard o )
- {
- float3 ase_worldPos = i.worldPos;
- float3 ase_worldViewDir = normalize( UnityWorldSpaceViewDir( ase_worldPos ) );
- float3 ase_worldNormal = i.worldNormal;
- float fresnelNdotV13 = dot( ase_worldNormal, ase_worldViewDir );
- float fresnelNode13 = ( 0.0 + _F * pow( 1.0 - fresnelNdotV13, 5.0 ) );
- o.Emission = ( tex2D( _TextureSample0, (i.uv_texcoord*1.0 + ( _Time.y * _Vector1 )) ) + tex2D( _TextureSample1, (i.uv_texcoord*1.0 + ( _Time.y * _Vector0 )) ) + ( fresnelNode13 * _Color0 ) ).rgb;
- o.Alpha = 1;
- }
- ENDCG
- CGPROGRAM
- #pragma surface surf Standard keepalpha fullforwardshadows
- ENDCG
- Pass
- {
- Name "ShadowCaster"
- Tags{ "LightMode" = "ShadowCaster" }
- ZWrite On
- CGPROGRAM
- #pragma vertex vert
- #pragma fragment frag
- #pragma target 3.0
- #pragma multi_compile_shadowcaster
- #pragma multi_compile UNITY_PASS_SHADOWCASTER
- #pragma skip_variants FOG_LINEAR FOG_EXP FOG_EXP2
- #include "HLSLSupport.cginc"
- #if ( SHADER_API_D3D11 || SHADER_API_GLCORE || SHADER_API_GLES || SHADER_API_GLES3 || SHADER_API_METAL || SHADER_API_VULKAN )
- #define CAN_SKIP_VPOS
- #endif
- #include "UnityCG.cginc"
- #include "Lighting.cginc"
- #include "UnityPBSLighting.cginc"
- struct v2f
- {
- V2F_SHADOW_CASTER;
- float2 customPack1 : TEXCOORD1;
- float3 worldPos : TEXCOORD2;
- float3 worldNormal : TEXCOORD3;
- UNITY_VERTEX_INPUT_INSTANCE_ID
- };
- v2f vert( appdata_full v )
- {
- v2f o;
- UNITY_SETUP_INSTANCE_ID( v );
- UNITY_INITIALIZE_OUTPUT( v2f, o );
- UNITY_TRANSFER_INSTANCE_ID( v, o );
- Input customInputData;
- float3 worldPos = mul( unity_ObjectToWorld, v.vertex ).xyz;
- half3 worldNormal = UnityObjectToWorldNormal( v.normal );
- o.worldNormal = worldNormal;
- o.customPack1.xy = customInputData.uv_texcoord;
- o.customPack1.xy = v.texcoord;
- o.worldPos = worldPos;
- TRANSFER_SHADOW_CASTER_NORMALOFFSET( o )
- return o;
- }
- half4 frag( v2f IN
- #if !defined( CAN_SKIP_VPOS )
- , UNITY_VPOS_TYPE vpos : VPOS
- #endif
- ) : SV_Target
- {
- UNITY_SETUP_INSTANCE_ID( IN );
- Input surfIN;
- UNITY_INITIALIZE_OUTPUT( Input, surfIN );
- surfIN.uv_texcoord = IN.customPack1.xy;
- float3 worldPos = IN.worldPos;
- half3 worldViewDir = normalize( UnityWorldSpaceViewDir( worldPos ) );
- surfIN.worldPos = worldPos;
- surfIN.worldNormal = IN.worldNormal;
- SurfaceOutputStandard o;
- UNITY_INITIALIZE_OUTPUT( SurfaceOutputStandard, o )
- surf( surfIN, o );
- #if defined( CAN_SKIP_VPOS )
- float2 vpos = IN.pos;
- #endif
- SHADOW_CASTER_FRAGMENT( IN )
- }
- ENDCG
- }
- }
- Fallback "Diffuse"
- CustomEditor "ASEMaterialInspector"
- }
- /*ASEBEGIN
- Version=16301
- 7;550;1906;641;2330.993;115.6177;1.6;True;True
- Node;AmplifyShaderEditor.TimeNode;10;-1460.24,318.8224;Float;False;0;5;FLOAT4;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.Vector2Node;18;-1773.931,203.9917;Float;False;Property;_Vector1;Vector 1;4;0;Create;True;0;0;False;0;0,0;0,0;0;3;FLOAT2;0;FLOAT;1;FLOAT;2
- Node;AmplifyShaderEditor.TimeNode;17;-1811.931,58.99165;Float;False;0;5;FLOAT4;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.Vector2Node;8;-1422.24,463.8224;Float;False;Property;_Vector0;Vector 0;3;0;Create;True;0;0;False;0;0,0;0,0;0;3;FLOAT2;0;FLOAT;1;FLOAT;2
- Node;AmplifyShaderEditor.SimpleMultiplyOpNode;20;-1519.931,129.9917;Float;False;2;2;0;FLOAT;0;False;1;FLOAT2;0,0;False;1;FLOAT2;0
- Node;AmplifyShaderEditor.TextureCoordinatesNode;4;-1383.24,191.8224;Float;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.RangedFloatNode;14;-517.4859,620.1577;Float;False;Property;_F;F;5;0;Create;True;0;0;False;0;0.93;0.93;0;0;0;1;FLOAT;0
- Node;AmplifyShaderEditor.TextureCoordinatesNode;19;-1734.931,-68.00835;Float;False;0;-1;2;3;2;SAMPLER2D;;False;0;FLOAT2;1,1;False;1;FLOAT2;0,0;False;5;FLOAT2;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.SimpleMultiplyOpNode;11;-1168.24,389.8224;Float;False;2;2;0;FLOAT;0;False;1;FLOAT2;0,0;False;1;FLOAT2;0
- Node;AmplifyShaderEditor.ScaleAndOffsetNode;3;-1046.551,260.7754;Float;False;3;0;FLOAT2;0,0;False;1;FLOAT;1;False;2;FLOAT2;0,0;False;1;FLOAT2;0
- Node;AmplifyShaderEditor.ColorNode;16;-290.6719,767.3306;Float;False;Property;_Color0;Color 0;2;0;Create;True;0;0;False;0;0,0,0,0;0,0,0,0;True;0;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.FresnelNode;13;-348.5195,538.8649;Float;True;Standard;WorldNormal;ViewDir;False;5;0;FLOAT3;0,0,1;False;4;FLOAT3;0,0,0;False;1;FLOAT;0;False;2;FLOAT;1;False;3;FLOAT;5;False;1;FLOAT;0
- Node;AmplifyShaderEditor.ScaleAndOffsetNode;21;-1398.242,0.9446492;Float;False;3;0;FLOAT2;0,0;False;1;FLOAT;1;False;2;FLOAT2;0,0;False;1;FLOAT2;0
- Node;AmplifyShaderEditor.SimpleMultiplyOpNode;15;29.58126,748.4461;Float;False;2;2;0;FLOAT;0;False;1;COLOR;0,0,0,0;False;1;COLOR;0
- Node;AmplifyShaderEditor.SamplerNode;2;-543.7498,312.13;Float;True;Property;_TextureSample1;Texture Sample 1;1;0;Create;True;0;0;False;0;None;None;True;0;False;white;Auto;False;Object;-1;Auto;Texture2D;6;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;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.SamplerNode;1;-619.7498,44.13004;Float;True;Property;_TextureSample0;Texture Sample 0;0;0;Create;True;0;0;False;0;None;None;True;0;False;white;Auto;False;Object;-1;Auto;Texture2D;6;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;5;COLOR;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
- Node;AmplifyShaderEditor.SimpleAddOpNode;12;144.6019,359.6633;Float;False;3;3;0;COLOR;0,0,0,0;False;1;COLOR;0,0,0,0;False;2;COLOR;0,0,0,0;False;1;COLOR;0
- Node;AmplifyShaderEditor.StandardSurfaceOutputNode;0;408,126;Float;False;True;2;Float;ASEMaterialInspector;0;0;Standard;New Amplify Shader;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;False;Back;0;False;-1;0;False;-1;False;0;False;-1;0;False;-1;False;0;Opaque;0.5;True;True;0;False;Opaque;;Geometry;All;True;True;True;True;True;True;True;True;True;True;True;True;True;True;True;True;True;0;False;-1;False;0;False;-1;255;False;-1;255;False;-1;0;False;-1;0;False;-1;0;False;-1;0;False;-1;0;False;-1;0;False;-1;0;False;-1;0;False;-1;False;2;15;10;25;False;0.5;True;0;0;False;-1;0;False;-1;0;0;False;-1;0;False;-1;0;False;-1;0;False;-1;0;False;0;0,0,0,0;VertexOffset;True;False;Cylindrical;False;Relative;0;;-1;-1;-1;-1;0;False;0;0;False;-1;-1;0;False;-1;0;0;0;False;0.1;False;-1;0;False;-1;16;0;FLOAT3;0,0,0;False;1;FLOAT3;0,0,0;False;2;FLOAT3;0,0,0;False;3;FLOAT;0;False;4;FLOAT;0;False;5;FLOAT;0;False;6;FLOAT3;0,0,0;False;7;FLOAT3;0,0,0;False;8;FLOAT;0;False;9;FLOAT;0;False;10;FLOAT;0;False;13;FLOAT3;0,0,0;False;11;FLOAT3;0,0,0;False;12;FLOAT3;0,0,0;False;14;FLOAT4;0,0,0,0;False;15;FLOAT3;0,0,0;False;0
- WireConnection;20;0;17;2
- WireConnection;20;1;18;0
- WireConnection;11;0;10;2
- WireConnection;11;1;8;0
- WireConnection;3;0;4;0
- WireConnection;3;2;11;0
- WireConnection;13;2;14;0
- WireConnection;21;0;19;0
- WireConnection;21;2;20;0
- WireConnection;15;0;13;0
- WireConnection;15;1;16;0
- WireConnection;2;1;3;0
- WireConnection;1;1;21;0
- WireConnection;12;0;1;0
- WireConnection;12;1;2;0
- WireConnection;12;2;15;0
- WireConnection;0;2;12;0
- ASEEND*/
- //CHKSM=92C444EADDD068080B96AA0852E7B648C870B338
|