Mercurial > hg > Game > Games
comparison Orchestland/Assets/LeapMotion/Widgets/Shaders/SelfIllumAlpha.shader @ 1:f7675884f2a1
Add Orchestland project
author | Daiki OYAKAWA <e135764@ie.u-ryukyu.ac.jp> |
---|---|
date | Fri, 17 Jul 2015 23:09:20 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
0:347d21cdfc22 | 1:f7675884f2a1 |
---|---|
1 Shader "SelfIllumAlpha" { | |
2 Properties { | |
3 _Color ("Main Color", Color) = (1,1,1,1) | |
4 _MainTex ("Texture", 2D) = "white" { } | |
5 } | |
6 SubShader { | |
7 Tags { "Queue" = "Transparent" } | |
8 Pass { | |
9 | |
10 | |
11 Cull Back | |
12 Blend SrcAlpha OneMinusSrcAlpha | |
13 | |
14 | |
15 CGPROGRAM | |
16 #pragma vertex vert | |
17 #pragma fragment frag | |
18 | |
19 #include "UnityCG.cginc" | |
20 | |
21 float4 _Color; | |
22 sampler2D _MainTex; | |
23 | |
24 struct v2f { | |
25 float4 pos : SV_POSITION; | |
26 float2 uv : TEXCOORD0; | |
27 }; | |
28 | |
29 float4 _MainTex_ST; | |
30 | |
31 v2f vert (appdata_base v) | |
32 { | |
33 v2f o; | |
34 o.pos = mul (UNITY_MATRIX_MVP, v.vertex); | |
35 o.uv = TRANSFORM_TEX (v.texcoord, _MainTex); | |
36 return o; | |
37 } | |
38 | |
39 half4 frag (v2f i) : COLOR | |
40 { | |
41 half4 texcol = tex2D (_MainTex, i.uv); | |
42 return texcol * _Color; | |
43 } | |
44 ENDCG | |
45 } | |
46 } | |
47 Fallback off | |
48 } |