logo
pub struct UnsafeImageBuilder { /* private fields */ }
Expand description

Used to construct a new UnsafeImage.

Implementations

Creates the UnsafeImage.

Panics
  • Panics if no dimensions were specified.
  • Panics if no format was specified.
  • Panics if no usage was specified.

The type, extent and number of array layers to create the image with.

There is no default value, this value must be provided.

Panics
  • Panics if one of the dimensions is zero.
  • Panics if the number of array layers is zero.

The external memory handle types that are going to be used with the image.

If any of the fields in this value are set, the device must either support API version 1.1 or the khr_external_memory extension must be enabled, and initial_layout must be set to Undefined.

The default value is ExternalMemoryHandleTypes::none().

Miscellaneous properties of the image.

The default value is ImageCreateFlags::none().

Panics
  • Panics if flags contains block_texel_view_compatible but not mutable_format.

The format used to store the image data.

There is no default value, this value must be provided.

The image layout that the image will have when it is created.

The default value is Undefined.

Panics

The number of mip levels to create the image with.

The default value is 1.

Panics

The number of samples per texel that the image should use.

The default value is Sample1.

Whether the image can be shared across multiple queues, or is limited to a single queue.

The default value is Exclusive.

Panics
  • Panics if sharing is Concurrent with less than 2 items.

The memory arrangement of the texel blocks.

The default value is Optimal.

How the image is going to be used.

There is no default value, this value must be provided.

Panics
  • Panics if usage has no bits set.
  • Panics if usage.transient_attachment is set, and usage does contain at least one of color_attachment, depth_stencil_attachment, input_attachment, or contains set flags other than these.

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

Builds a pointer to this type from a raw pointer.

Returns true if the size is suitable to store a type like this.

Returns the size of an individual element.

Performs the conversion.

Performs the conversion.

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.