UniversalViewer/Assets/KF3/Shader/KemonoAlpha.shader

72 lines
3.6 KiB
Plaintext
Raw Normal View History

// Made with Amplify Shader Editor
// Available at the Unity Asset Store - http://u3d.as/y3X
Shader "KemonoDepth"
{
Properties
{
_Outline_Width("Outline_Width", Float) = 0
_MainTex("MainTex", 2D) = "white" {}
[HideInInspector] _texcoord( "", 2D ) = "white" {}
[HideInInspector] __dirty( "", Int ) = 1
}
SubShader
{
Tags{ "RenderType" = "Transparent" "Queue" = "AlphaTest+0" "IgnoreProjector" = "True" "IsEmissive" = "true" }
Cull Back
ZWrite On
ZTest Always
Blend One One
AlphaToMask On
CGPROGRAM
#pragma target 3.0
#pragma surface surf Standard keepalpha noshadow vertex:vertexDataFunc
struct Input
{
float2 uv_texcoord;
};
uniform float _Outline_Width;
uniform sampler2D _MainTex;
SamplerState sampler_MainTex;
uniform float4 _MainTex_ST;
void vertexDataFunc( inout appdata_full v, out Input o )
{
UNITY_INITIALIZE_OUTPUT( Input, o );
float3 ase_vertexNormal = v.normal.xyz;
v.vertex.xyz += ( ase_vertexNormal * ( _Outline_Width * 0.001 ) );
v.vertex.w = 1;
}
void surf( Input i , inout SurfaceOutputStandard o )
{
float2 uv_MainTex = i.uv_texcoord * _MainTex_ST.xy + _MainTex_ST.zw;
float4 tex2DNode15 = tex2D( _MainTex, uv_MainTex );
float3 temp_cast_0 = (tex2DNode15.a).xxx;
o.Emission = temp_cast_0;
o.Alpha = tex2DNode15.a;
}
ENDCG
}
CustomEditor "ASEMaterialInspector"
}
/*ASEBEGIN
Version=18500
1136;278;1382;654;1112.095;125.5801;1.151147;True;False
Node;AmplifyShaderEditor.RangedFloatNode;4;-499.1572,463.9675;Inherit;False;Property;_Outline_Width;Outline_Width;0;0;Create;True;0;0;False;0;False;0;1;0;0;0;1;FLOAT;0
Node;AmplifyShaderEditor.NormalVertexDataNode;8;-496.1572,273.9675;Inherit;False;0;5;FLOAT3;0;FLOAT;1;FLOAT;2;FLOAT;3;FLOAT;4
Node;AmplifyShaderEditor.ScaleNode;10;-299.9144,458.9795;Inherit;False;0.001;1;0;FLOAT;0;False;1;FLOAT;0
Node;AmplifyShaderEditor.SimpleMultiplyOpNode;9;-201.1572,322.9675;Inherit;False;2;2;0;FLOAT3;0,0,0;False;1;FLOAT;0;False;1;FLOAT3;0
Node;AmplifyShaderEditor.SamplerNode;15;-709.3722,-52.49344;Inherit;True;Property;_MainTex;MainTex;1;0;Create;True;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
Node;AmplifyShaderEditor.StandardSurfaceOutputNode;13;1,0;Float;False;True;-1;2;ASEMaterialInspector;0;0;Standard;KemonoDepth;False;False;False;False;False;False;False;False;False;False;False;False;False;False;True;False;False;False;False;False;False;Back;1;False;-1;7;False;-1;False;0;False;-1;0;False;-1;False;0;Custom;0.5;True;False;0;True;Transparent;;AlphaTest;All;14;all;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;False;4;1;False;-1;1;False;-1;0;5;False;-1;10;False;-1;0;False;-1;0;False;-1;0;False;0;0,0,0,0;VertexOffset;True;False;Cylindrical;False;Relative;0;;2;-1;-1;-1;0;True;0;0;False;-1;-1;0;False;-1;0;0;0;False;0.1;False;-1;0;False;-1;False;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;10;0;4;0
WireConnection;9;0;8;0
WireConnection;9;1;10;0
WireConnection;13;2;15;4
WireConnection;13;9;15;4
WireConnection;13;11;9;0
ASEEND*/
//CHKSM=487328B6E22BAE0DE9E8F0D6F2DDC8E0729724B2