Struct sierra::Device[][src]

#[repr(transparent)]
pub struct Device { /* fields omitted */ }
Expand description

Opaque value that represents graphics API device. It is used to manage (create, destroy, check state) most of the device resources.

Implementations

Returns graphics associated with the device instance.

Returns weak reference to this device.

Creates buffer with uninitialized content.

Creates buffer with uninitialized content.

Creates static buffer with preinitialized content from data. Implies MemoryUsage::Device.

Panics

Function will panic if creating buffer size does not equal data size. E.g. if info.size != std::mem::size_of(data).

Creates a fence. Fences are create in unsignaled state.

Creates framebuffer for specified render pass from views.

Creates graphics pipeline.

Creates compute pipeline.

Creates image with uninitialized content.

Creates view to an image.

Creates pipeline layout.

Creates render pass.

Creates semaphore. Semaphores are created in unsignaled state.

Creates new shader module from shader’s code.

Creates swapchain for specified surface. Only one swapchain may be associated with one surface.

Resets fences. All specified fences must be in signalled state. Fences are moved into unsignalled state.

Checks if fence is in signalled state.

Wait for fences to become signaled. If all is true - waits for all specified fences to become signaled. Otherwise waits for at least on of specified fences to become signaled. May return immediately if all fences are already signaled (or at least one is signaled if all == false). Fences are signaled by Queues. See Queue::submit.

Wait for whole device to become idle. That is, wait for all pending operations to complete. This is equivalent to calling Queue::wait_idle for all queues. Typically used only before device destruction.

Returns memory size requirements for accelelration structure build operations.

Creates acceleration structure.

Panics

This method may panic if Feature::RayTracing wasn’t enabled.

Returns buffers device address.

Returns device address of acceleration strucutre.

Creates ray-tracing pipeline.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.