[][src]Struct bedrock::Device

pub struct Device(_);

Opaque handle to a device object

Methods

impl Device[src]

Following methods are enabled with [feature = "Implements"]

pub fn extra_procedure<F: FnTransmute>(&self, name: &str) -> Option<F>[src]

Return a function pointer for a command

Failures

If function is not provided by instance or name is empty, returns None

pub fn queue(&self, family_index: u32, queue_index: u32) -> Queue[src]

Get a queue handle from a device

pub unsafe fn invalidate_memory_range(
    &self,
    ranges: &[VkMappedMemoryRange]
) -> Result<()>
[src]

Invalidate MappedMemoryRanges Invalidating the memory range allows that device writes to the memory ranges which have been made visible to the VK_ACCESS_HOST_WRITE_BIT and VK_ACCESS_HOST_READ_BIT are made visible to the host

Safety

Memory object in ranges must be currently host mapped

pub fn update_descriptor_sets(
    &self,
    write: &[DescriptorSetWriteInfo],
    copy: &[DescriptorSetCopyInfo]
)
[src]

Update the contents of a descriptor set object

impl Device[src]

pub fn bind_buffers(
    &self,
    bounds: &[(&Buffer, &DeviceMemory, VkDeviceSize)]
) -> Result<()>
[src]

Multiple Binding for Buffers

pub fn bind_images(
    &self,
    bounds: &[(&Image, &DeviceMemory, VkDeviceSize)]
) -> Result<()>
[src]

Multiple Binding for Images

pub fn bind_resources(
    &self,
    buf_bounds: &[(&Buffer, &DeviceMemory, VkDeviceSize)],
    img_bounds: &[(&Image, &DeviceMemory, VkDeviceSize)]
) -> Result<()>
[src]

Multiple Binding for both resources

impl Device[src]

pub unsafe fn flush_mapped_memory_ranges(
    &self,
    ranges: &[VkMappedMemoryRange]
) -> Result<()>
[src]

Flush MappedMemoryRanges Flushing the memory range allows that host writes to the memory ranges can be made available to device access

Safety

Memory object in ranges must be currently host mapped

impl Device[src]

Following methods are enabled with [feature = "Implements"]

pub fn create_graphics_pipelines(
    &self,
    builders: &[GraphicsPipelineBuilder],
    cache: Option<&PipelineCache>
) -> Result<Vec<Pipeline>>
[src]

Create graphics pipelines

Failures

On failure, this command returns

  • VK_ERROR_OUT_OF_HOST_MEMORY
  • VK_ERROR_OUT_OF_DEVICE_MEMORY

impl Device[src]

Following methods are enabled with [feature = "Implements"]

pub fn create_compute_pipelines(
    &self,
    builders: &[ComputePipelineBuilder],
    cache: Option<&PipelineCache>
) -> Result<Vec<Pipeline>>
[src]

Create compute pipelines

Failures

On failure, this command returns

  • VK_ERROR_OUT_OF_HOST_MEMORY
  • VK_ERROR_OUT_OF_DEVICE_MEMORY

Trait Implementations

impl Clone for Device[src]

impl VkHandle for Device[src]

type Handle = VkDevice

impl Waitable for Device[src]

Auto Trait Implementations

impl !RefUnwindSafe for Device

impl !Send for Device

impl !Sync for Device

impl Unpin for Device

impl !UnwindSafe for Device

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> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.