Struct nannou::wgpu::Instance [−][src]
pub struct Instance { /* fields omitted */ }
Expand description
Implementations
pub fn request_adapter(
&self,
options: &RequestAdapterOptions<&Surface>
) -> impl Future<Output = Option<Adapter>> + Send
pub fn request_adapter(
&self,
options: &RequestAdapterOptions<&Surface>
) -> impl Future<Output = Option<Adapter>> + Send
Retrieves an Adapter
which matches the given RequestAdapterOptions
.
Some options are “soft”, so treated as non-mandatory. Others are “hard”.
If no adapters are found that suffice all the “hard” options, None
is returned.
pub unsafe fn create_adapter_from_hal<A>(
&self,
hal_adapter: ExposedAdapter<A>
) -> Adapter where
A: HalApi,
pub unsafe fn create_adapter_from_hal<A>(
&self,
hal_adapter: ExposedAdapter<A>
) -> Adapter where
A: HalApi,
Creates a surface from a raw window handle.
Safety
- Raw Window Handle must be a valid object to create a surface upon and must remain valid for the lifetime of the returned surface.
Polls all devices.
If force_wait
is true and this is not running on the web,
then this function will block until all in-flight buffers have been mapped.
Generates memory report.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Instance
impl !UnwindSafe for Instance
Blanket Implementations
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
T: Component + Float,
Swp: WhitePoint,
Dwp: WhitePoint,
D: AdaptFrom<S, Swp, Dwp, T>,
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
T: Component + Float,
Swp: WhitePoint,
Dwp: WhitePoint,
D: AdaptFrom<S, Swp, Dwp, T>,
Mutably borrows from an owned value. Read more
Convert into T with values clamped to the color defined bounds Read more
Convert into T. The resulting color might be invalid in its color space Read more
Convert into T, returning ok if the color is inside of its defined range,
otherwise an OutOfBounds
error is returned which contains the unclamped color. Read more