la unidad mezclar dos texturas de sombreado

Shader "Blend 2 texturas, simplemente Lit" { 
 
propiedades {
_Color ( "color", en color) = (1,1,1)
_Blend ( "mezcla", Cadena de (0,1)) = 0,5 
_MainTex ( "Textura 1", 2D) = "" 
_Texture2 ( "Textura 2", 2D) = ""
}
 
Categoría {
Material {
Ambiente [_Color]
Diffuse [_Color]
}
 
// iPhone 3GS y más tarde
SubShader {{Pass
En la iluminación
SetTexture [_MainTex]
SetTexture [_Texture2] { 
ConstantColor (0,0,0, [_Blend]) 
Combinar la textura Lerp (constante) anterior
}
SetTexture [_] {Combinar anterior * Doble primaria}
}}
 
// pre-3GS dispositivos, incluyendo el número de septiembre 2009 de 8 GB iPod touch
SubShader {
Pasar {
SetTexture [_MainTex]
SetTexture [_Texture2] {
ConstantColor (0,0,0, [_Blend])
Combinar la textura Lerp (constante) anterior
}
}
Pasar {
En la iluminación
Mezclar DstColor SrcColor
}
}
}
 


发布了20 篇原创文章 · 获赞 0 · 访问量 1万+

Supongo que te gusta

Origin blog.csdn.net/gcj2450/article/details/45095497
Recomendado
Clasificación