pub fn with_blended_output(
        &mut self,
        name: &'a str,
        mask: ColorMask,
        blend: Blend,
        depth: Option<DepthMode>,
    ) -> &mut Self {
        if let Some(depth) = depth {
            self.init.out_depth = Some((
                match depth {
                    DepthMode::LessEqualTest => LESS_EQUAL_TEST,
                    DepthMode::LessEqualWrite => LESS_EQUAL_WRITE,
                },
                Stencil::default(),
            ));
        }
        // OSX doesn't seem to work without a depth test, so here's a workaround.
        if cfg!(target_os = "macos") && depth.is_none() {
            self.init.out_depth = Some((
                Depth {
                    fun: Comparison::Always,
                    write: true,
                },
                Stencil::default(),
            ));
        }
        self.init.out_blends.push((name, mask, blend));
        self
    }
/// Sets the output target of the PSO.
///
/// If the target contains a depth buffer, its mode will be set by `depth`.
Sets the output target of the PSO.
If the target contains a depth buffer, its mode will be set by `depth`.
Sets the output target of the PSO . If the target contains a depth buffer its mode will be set by ` depth ` .
pub fn with_blended_output(
        &mut self,
        name: &'a str,
        mask: ColorMask,
        blend: Blend,
        depth: Option<DepthMode>,
    ) -> &mut Self {
        if let Some(depth) = depth {
            self.init.out_depth = Some((
                match depth {
                    DepthMode::LessEqualTest => LESS_EQUAL_TEST,
                    DepthMode::LessEqualWrite => LESS_EQUAL_WRITE,
                },
                Stencil::default(),
            ));
        }
        // OSX doesn't seem to work without a depth test, so here's a workaround.
        if cfg!(target_os = "macos") && depth.is_none() {
            self.init.out_depth = Some((
                Depth {
                    fun: Comparison::Always,
                    write: true,
                },
                Stencil::default(),
            ));
        }
        self.init.out_blends.push((name, mask, blend));
        self
    }
pub fn with_blended_output ( & mut self , name : & ' a str , mask : ColorMask , blend : Blend , depth : Option < DepthMode > , ) -> & mut Self { if let Some ( depth ) = depth { self . init . out_depth = Some ( ( match depth { DepthMode :: LessEqualTest => LESS_EQUAL_TEST , DepthMode :: LessEqualWrite => LESS_EQUAL_WRITE , } , Stencil :: default ( ) , ) ) ; } // OSX doesn't seem to work without a depth test, so here's a workaround. if cfg ! ( target_os " " ) && depth . is_none ( ) { self . init . out_depth = Some ( ( Depth { fun : Comparison :: Always , write : true , } , Stencil :: default ( ) , ) ) ; } self . init . out_blends . push ( ( name , mask , blend ) ) ; self }
Sets the output target of the PSO.
Sets the output target of the PSO .
&mut self
name
&'a str
mask
ColorMask
blend
Blend
depth
Option<DepthMode>
&mut self
name
&'a str
mask
ColorMask
blend
Blend
depth
Option<DepthMode>