pub trait HalApi: Api + 'static + WasmNotSendSync {
    const VARIANT: Backend;

    // Required methods
    fn create_instance_from_hal(
        name: &str,
        hal_instance: Self::Instance
    ) -> Instance;
    fn instance_as_hal(instance: &Instance) -> Option<&Self::Instance>;
    fn hub<G>(global: &Global<G>) -> &Hub<Self>
       where G: GlobalIdentityHandlerFactory;
    fn get_surface(surface: &Surface) -> Option<&HalSurface<Self>>;
}
Available on crate feature wgpu only.

Required Associated Constants§

Required Methods§

fn create_instance_from_hal( name: &str, hal_instance: Self::Instance ) -> Instance

fn instance_as_hal(instance: &Instance) -> Option<&Self::Instance>

fn hub<G>(global: &Global<G>) -> &Hub<Self>

fn get_surface(surface: &Surface) -> Option<&HalSurface<Self>>

Object Safety§

This trait is not object safe.

Implementors§

§

impl HalApi for iced::widget::shader::wgpu::hal::empty::Api

§

const VARIANT: Backend = Backend::Empty

§

impl HalApi for iced::widget::shader::wgpu::hal::gles::Api

Available on gles only.
§

const VARIANT: Backend = Backend::Gl

§

impl HalApi for iced::widget::shader::wgpu::hal::vulkan::Api

Available on vulkan only.
§

const VARIANT: Backend = Backend::Vulkan