美文网首页
双面渲染

双面渲染

作者: 萧非子 | 来源:发表于2017-11-09 16:35 被阅读20次

Shader "Custom/DoubleShader" {
Properties {
_Color ("Main Color", Color) = (1,1,1,1)//Tint Color
_MainTex ("Base (RGB)", 2D) = "white" {}
_MainTex_2 ("Base (RGB)", 2D) = "white" {}
}

SubShader {
Tags { "RenderType"="Opaque" }
LOD 100

Pass {  
    Cull Front  
    Lighting Off  
    SetTexture [_MainTex] { combine texture }   
    SetTexture [_MainTex]  
    {  
        ConstantColor [_Color]  
        Combine Previous * Constant  
    }  
}  

Pass  
{  
    Cull Back  
    Lighting Off  
    SetTexture [_MainTex_2] { combine texture }   
    SetTexture [_MainTex_2]  
    {  
        ConstantColor [_Color]  
        Combine Previous * Constant  
    }  
}  

}
}

相关文章

网友评论

      本文标题:双面渲染

      本文链接:https://www.haomeiwen.com/subject/iphmmxtx.html