[][src]Struct web_glitz::rendering::DepthBuffer

pub struct DepthBuffer<F> { /* fields omitted */ }

Represents a depth-stencil buffer that stores only depth values in a framebuffer for a custom render target.

Implementations

impl<F> DepthBuffer<F>[src]

pub fn clear_command(&self, depth: f32, region: Region2D) -> ClearDepthCommand[src]

Returns a command that clears all depth values in the region to depth.

Values outside the region are unaffected.

Examples

The following command will clear the entire depth-stencil buffer to a depth value of 1.0:

let command = buffer.clear_command(1.0, Region2D::Fill);

It's also possible to only clear a specific rectangular area of the buffer:

let command = buffer.clear_command(1.0, Region2D::Area((0, 0), 100, 100));

See also Region2D.

Trait Implementations

impl<F> RenderingOutputBuffer for DepthBuffer<F> where
    F: InternalFormat
[src]

type Format = F

The type image storage format used by the buffer.

Auto Trait Implementations

impl<F> RefUnwindSafe for DepthBuffer<F> where
    F: RefUnwindSafe

impl<F> Send for DepthBuffer<F> where
    F: Send

impl<F> Sync for DepthBuffer<F> where
    F: Sync

impl<F> Unpin for DepthBuffer<F>

impl<F> UnwindSafe for DepthBuffer<F> where
    F: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<D, T> IntoBuffer<T> for D where
    D: Borrow<T> + 'static,
    T: Copy + 'static, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.