Shader "Custom/test001" {
Properties {
_MainTex ("图片", 2D) = "blue" {}
_Myfloat("浮点数",Float)=0.2
_MyRange("数值范围",range(0,2))=1.0
_MyVector("向量值",vector)=(1,1,1,1)
_MyColor("颜色",Color)=(1,1,1,1)
_MyRect("矩形",rect)="white"{}
}
SubShader {
Tags { "RenderType"="Opaque" }
LOD 200
CGPROGRAM
#pragma surface surf Lambert
sampler2D _MainTex;
struct Input {
float2 uv_MainTex;
};
void surf (Input IN, inout SurfaceOutput o) {
half4 c = tex2D (_MainTex, IN.uv_MainTex);
o.Albedo = c.rgb;
o.Alpha = c.a;
}
ENDCG
}
FallBack "Diffuse"
}
Properties {
_MainTex ("图片", 2D) = "blue" {}
_Myfloat("浮点数",Float)=0.2
_MyRange("数值范围",range(0,2))=1.0
_MyVector("向量值",vector)=(1,1,1,1)
_MyColor("颜色",Color)=(1,1,1,1)
_MyRect("矩形",rect)="white"{}
}
SubShader {
Tags { "RenderType"="Opaque" }
LOD 200
CGPROGRAM
#pragma surface surf Lambert
sampler2D _MainTex;
struct Input {
float2 uv_MainTex;
};
void surf (Input IN, inout SurfaceOutput o) {
half4 c = tex2D (_MainTex, IN.uv_MainTex);
o.Albedo = c.rgb;
o.Alpha = c.a;
}
ENDCG
}
FallBack "Diffuse"
}