Created
July 22, 2014 17:51
-
-
Save increpare/e33e5bb0eff9fb18fcfb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
produce the error | |
Shader error in 'Custom/UV2Test': declaration of "_MainTex_ST" conflicts with previous declaration at (48) at line 49 | |
*/ | |
Shader "Custom/UV2Test" { | |
Properties { | |
_MainTex ("Base (RGB)", 2D) = "white" {} | |
} | |
SubShader { | |
Tags { "RenderType"="Opaque" } | |
LOD 200 | |
CGPROGRAM | |
#pragma surface surf Lambert | |
sampler2D _MainTex; | |
struct Input { | |
float2 uv_MainTex; | |
float2 uv2_MainTex; | |
}; | |
void surf (Input IN, inout SurfaceOutput o) { | |
half4 c = tex2D (_MainTex, IN.uv_MainTex); | |
o.Albedo = c.rgb; | |
o.Alpha = c.a; | |
o.Emission = float3(IN.uv2_MainTex.x,IN.uv2_MainTex.y,0); | |
} | |
ENDCG | |
} | |
FallBack "Diffuse" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment