Trait nannou_wgpu::ToTextureView[][src]

pub trait ToTextureView {
    fn to_texture_view(&self) -> TextureView;
}
Expand description

Types that can produce a texture view.

The primary purpose of this trait is to allow for APIs to be generic over both Texture and TextureView. This is particularly useful for the draw API as we can avoid needing users to understand the difference between the two. That said, it is slightly more efficient to create your texture view once and re-use it, rather than have these APIs create a new one from your texture each time they are invoked.

Required methods

Implementations on Foreign Types

Implementors