Struct vulkano::command_buffer::pool::UnsafeCommandPool [] [src]

pub struct UnsafeCommandPool { /* fields omitted */ }

Low-level implementation of a command pool.

A command pool is always tied to a specific queue family. Command buffers allocated from a pool can only be executed on the corresponding queue familiy.

This struct doesn't implement the Sync trait because Vulkan command pools are not thread safe. In other words, you can only use a pool from one thread at a time.

Methods

impl UnsafeCommandPool
[src]

[src]

Creates a new pool.

The command buffers created with this pool can only be executed on queues of the given family.

Setting transient to true is a hint to the implementation that the command buffers will be short-lived. Setting reset_cb to true means that command buffers can be reset individually.

Panic

  • Panics if the queue family doesn't belong to the same physical device as device.

[src]

Resets the pool, which resets all the command buffers that were allocated from it.

If release_resources is true, it is a hint to the implementation that it should free all the memory internally allocated for this pool.

Safety

The command buffers allocated from this pool jump to the initial state.

[src]

Trims a command pool, which recycles unused internal memory from the command pool back to the system.

Command buffers allocated from the pool are not affected by trimming.

This function is supported only if the VK_KHR_maintenance1 extension was enabled at device creation. Otherwise an error is returned. Since this operation is purely an optimization it is legitimate to call this function and simply ignore any possible error.

[src]

Allocates count command buffers.

If secondary is true, allocates secondary command buffers. Otherwise, allocates primary command buffers.

[src]

Frees individual command buffers.

Safety

The command buffers must have been allocated from this pool. They must not be in use.

[src]

Returns the queue family on which command buffers of this pool can be executed.

Trait Implementations

impl Debug for UnsafeCommandPool
[src]

[src]

Formats the value using the given formatter. Read more

impl Send for UnsafeCommandPool
[src]

impl DeviceOwned for UnsafeCommandPool
[src]

[src]

Returns the device that owns Self.

impl VulkanObject for UnsafeCommandPool
[src]

The type of the object.

TYPE: DebugReportObjectTypeEXT = vk::DEBUG_REPORT_OBJECT_TYPE_COMMAND_POOL_EXT

The DebugReportObjectTypeEXT of the internal Vulkan handle.

[src]

Returns a reference to the object.

impl Drop for UnsafeCommandPool
[src]

[src]

Executes the destructor for this type. Read more

Auto Trait Implementations