Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
half Specular;
half Gloss;
half Alpha;
};
struct Input {
half2 uv_MainTex;
half3 viewDir;
half4 GrabUV;
half4 proj : TEXCOORD;
half4 screenPos;
};
void vert (inout appdata_full v, out Input o){
half4 oPos = mul(UNITY_MATRIX_MVP, v.vertex);
#if UNITY_UV_STARTS_AT_TOP
half scale = -1.0;
#else
half scale = 1.0;
#endif
o.proj.xy = (half2(oPos.x, oPos.y*scale) + oPos.
w) * 0.5;
o.proj.zw = oPos.zw;
}
sampler2D _GrabTexture;
float4 _GrabTexture_TexelSize;
half w;
half n;
half _AlbedoIn;
sampler2D _RampR;
half
half
half
half
half
half
_BumpAmt;
_TransAmount;
_BorderPower;
_Pow0AIn;
_RimPower;
_Pow0BIn;
sampler2D _MainTex;
sampler2D _BumpMap;
half _Shininess;
half _ShininessIn;
half _Power;
half _Distortion;
half _Scale;
half _Power2;
half _Distortion2;
half _Scale2;
half4 LightingTEST (MAPSurfaceOutput s, half3 lightDir,
half3 viewDir, half atten) {
// Translucency.
half3 transLightDir = lightDir + s.Normal * _Dis
tortion;
float transDot1 = pow ( max (0, dot ( viewDir, -