Struct imgui_wgpu::RendererConfig[][src]

pub struct RendererConfig<'vs, 'fs> {
    pub texture_format: TextureFormat,
    pub depth_format: Option<TextureFormat>,
    pub sample_count: u32,
    pub vertex_shader: Option<ShaderModuleDescriptor<'vs>>,
    pub fragment_shader: Option<ShaderModuleDescriptor<'fs>>,
}

Configuration for the renderer.

Fields

texture_format: TextureFormatdepth_format: Option<TextureFormat>sample_count: u32vertex_shader: Option<ShaderModuleDescriptor<'vs>>fragment_shader: Option<ShaderModuleDescriptor<'fs>>

Implementations

impl RendererConfig<'_, '_>[src]

pub fn with_shaders<'vs, 'fs>(
    vertex_shader: ShaderModuleDescriptor<'vs>,
    fragment_shader: ShaderModuleDescriptor<'fs>
) -> RendererConfig<'vs, 'fs>
[src]

Create a new renderer config with custom shaders.

impl RendererConfig<'_, '_>[src]

pub fn new() -> Self[src]

Create a new renderer config with precompiled default shaders outputting linear color.

If you write to a Bgra8UnormSrgb framebuffer, this is what you want.

pub fn new_srgb() -> Self[src]

Create a new renderer config with precompiled default shaders outputting srgb color.

If you write to a Bgra8Unorm framebuffer, this is what you want.

Trait Implementations

impl Default for RendererConfig<'_, '_>[src]

fn default() -> Self[src]

Create a new renderer config with precompiled default shaders outputting linear color.

If you write to a Bgra8UnormSrgb framebuffer, this is what you want.

Auto Trait Implementations

impl<'vs, 'fs> RefUnwindSafe for RendererConfig<'vs, 'fs>[src]

impl<'vs, 'fs> Send for RendererConfig<'vs, 'fs>[src]

impl<'vs, 'fs> Sync for RendererConfig<'vs, 'fs>[src]

impl<'vs, 'fs> Unpin for RendererConfig<'vs, 'fs>[src]

impl<'vs, 'fs> UnwindSafe for RendererConfig<'vs, 'fs>[src]

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> Downcast<T> for T

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

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[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.

impl<T> Upcast<T> for T