Struct vulkano::memory::DeviceMemory [] [src]

pub struct DeviceMemory<D = Arc<Device>> where D: SafeDeref<Target=Device> { /* fields omitted */ }

Represents memory that has been allocated.

Methods

impl<D> DeviceMemory<D> where D: SafeDeref<Target=Device>
[src]

Allocates a chunk of memory from the device.

Some platforms may have a limit on the maximum size of a single allocation. For example, certain systems may fail to create allocations with a size greater than or equal to 4GB.

Panic

  • Panics if size is 0.
  • Panics if memory_type doesn't belong to the same physical device as device.

Allocates a chunk of memory and maps it.

Panic

  • Panics if memory_type doesn't belong to the same physical device as device.
  • Panics if the memory type is not host-visible.

Returns the memory type this chunk was allocated on.

Returns the size in bytes of that memory chunk.

Returns the device associated with this allocation.

Trait Implementations

impl<D: Debug> Debug for DeviceMemory<D> where D: SafeDeref<Target=Device>
[src]

Formats the value using the given formatter.

impl<D> VulkanObject for DeviceMemory<D> where D: SafeDeref<Target=Device>
[src]

The type of the object.

Returns a reference to the object.

impl<D> Drop for DeviceMemory<D> where D: SafeDeref<Target=Device>
[src]

A method called when the value goes out of scope. Read more