纳金网
标题:
双法线转换的脚本
[打印本页]
作者:
狂风大尉
时间:
2014-6-23 01:41
标题:
双法线转换的脚本
Shader "New Shader" {
Properties {
_Color("Main Color",Color)=(1,1,1,1)
_MainTex ("Base (RGB)", 2D) = "white" {}
}
SubShader {
Pass{
Name "BASE"
Tags{"LightMode" = "Always" /* Upgrade NOTE: changed from PixelOrNone to Always */}
Color[_PPLAmbient]
SetTexture[_BumpMap]
{
constantColor (.5,.5,.5)
combine constant lerp (texture) previous
}
SetTexture [_MainTex]
{
constantColor[_Color]
Combine texture * previous DOUBLE,texture*constant
}
}
Pass{
Name "BASE"
Tags{"LightMode" = "Vertex"}
Material{
Diffuse [_Color]
Emission [_PPLAmbient]
Shininess [_Shininess]
Specular [_SpecColor]
}
SeparateSpecular On
Lighting On
Cull Off
SetTexture[_BumpMap]
{
constantColor(.5,.5,.5)
combine constant lerp (texture) previous
}
SetTexture[_MainTex]
{
Combine texture*previous DOUBLE,texture*primary
}
}
}
FallBack "Diffuse",1
}
作者:
hyui
时间:
2014-6-23 02:33
Great to learn from code! thank you!
作者:
Kadina
时间:
2014-6-23 06:38
Thank you for sharing your knowledge!
欢迎光临 纳金网 (http://course.narkii.com/club/)
Powered by Discuz! X2.5