码迷,mamicode.com
首页 > 其他好文 > 详细

Blending

时间:2014-07-26 14:53:40      阅读:306      评论:0      收藏:0      [点我收藏+]

标签:style   blog   http   color   os   strong   io   2014   

Blending

  Blending is used to make transparent objects.

  bubuko.com,布布扣

  When graphics are rendered, after all shaders have executed and all textures have been applied, the pixels are written to the screen. How they are combined with what is already there is controlled by the Blend command.

[Syntax]

  bubuko.com,布布扣

[Blend Operations]

  bubuko.com,布布扣

[Blend factors]

  bubuko.com,布布扣

[常用混合类型]

  bubuko.com,布布扣

[Examples]

1、Here is a small example shader that adds a texture to whatever is on the screen already:

bubuko.com,布布扣
Shader "Simple Additive" {
    Properties {
        _MainTex ("Texture to blend", 2D) = "black" {}
    }
    SubShader {
        Tags { "Queue" = "Transparent" }
        Pass {
            Blend One One
            SetTexture [_MainTex] { combine texture }
        }
    }
}
View Code

参考:file://localhost/Applications/Unity/Unity.app/Contents/Documentation/Documentation/Components/SL-Blend.html

Blending,布布扣,bubuko.com

Blending

标签:style   blog   http   color   os   strong   io   2014   

原文地址:http://www.cnblogs.com/tekkaman/p/3870039.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!