[][src]Struct thyme::WgpuRenderer

pub struct WgpuRenderer { /* fields omitted */ }

A Thyme Renderer for wgpu.

The adapter registers image and font data as textures, and renders each frame.

This renderer is implemented fairly naively at present and there is definitely room for optimization. However, it is nonetheless already quite fast.

See the thyme examples for how to setup and use this renderer.

Implementations

impl WgpuRenderer[src]

pub fn new(device: Rc<Device>, queue: Rc<Queue>) -> WgpuRenderer[src]

Creates a new wgpu renderer, using the specified device and queue. For now, these must be wrapped in an Rc so the renderer can hold on to a reference, but this should be relaxed in the future.

pub fn draw_frame<'a>(
    &'a mut self,
    frame: Frame,
    render_pass: &mut RenderPass<'a>
)
[src]

Draws the current Frame to the screen

Trait Implementations

impl<'a> Renderer for WgpuRenderer[src]

Auto Trait Implementations

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<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.