Struct glium::draw_parameters::Blend
[−]
[src]
pub struct Blend { pub color: BlendingFunction, pub alpha: BlendingFunction, pub constant_value: (f32, f32, f32, f32), }
Blend effect that the GPU will use for blending.
Blending happens at the end of the rendering process, when the GPU wants to write the pixels over pixels that already exist in the framebuffer. The blending function allows you to choose how it should merge the two.
If you want to add transparent objects one over another, use
Blend::alpha_blending()
.
Fields
color | The blending function for color channels. |
alpha | The blending function for alpha channels. |
constant_value | A constant color that can be used in the blending functions. |
Methods
impl Blend
fn alpha_blending() -> Blend
Returns a blend effect to add transparent objects over others.