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: BlendingFunction
The blending function for color channels.
alpha: BlendingFunction
The blending function for alpha channels.
constant_value: (f32, f32, f32, f32)
A constant color that can be used in the blending functions.
Methods
impl Blend
[src]
pub fn alpha_blending() -> Blend
[src]
Returns a blend effect to add transparent objects over others.
Trait Implementations
impl Copy for Blend
[src]
impl Clone for Blend
[src]
fn clone(&self) -> Blend
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for Blend
[src]
impl PartialEq for Blend
[src]
fn eq(&self, __arg_0: &Blend) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Blend) -> bool
[src]
This method tests for !=
.