Struct vulkano::render_pass::AttachmentReference
source · pub struct AttachmentReference {
pub attachment: u32,
pub layout: ImageLayout,
pub stencil_layout: Option<ImageLayout>,
pub aspects: ImageAspects,
pub _ne: NonExhaustive,
}
Expand description
A reference to an attachment in a subpass description of a render pass.
Fields§
§attachment: u32
The number of the attachment being referred to.
The default value is 0
.
layout: ImageLayout
The image layout that the attachment should be transitioned to at the start of the subpass.
The layout is restricted by the type of attachment that an attachment is being used as. A full listing of allowed layouts per type can be found in the Vulkan specification.
The default value is ImageLayout::Undefined
, which must be overridden.
stencil_layout: Option<ImageLayout>
The layout
of the stencil aspect of the attachment, if different.
The layout is restricted by the type of attachment that an attachment is being used as. A full listing of allowed layouts per type can be found in the Vulkan specification.
If this is Some
, then the
separate_depth_stencil_layouts
feature must be enabled on the device.
The default value is None
.
aspects: ImageAspects
For references to input attachments, the aspects of the image that should be selected. For attachment types other than input attachments, the value must be empty.
If empty, all aspects available in the input attachment’s format
will be selected.
If any fields are set, they must be aspects that are available in the format
of the
attachment.
If the value is neither empty nor identical to the aspects of the format
, the device API
version must be at least 1.1, or either the
khr_create_renderpass2
or the
khr_maintenance2
extensions must be
enabled on the device.
The default value is ImageAspects::empty()
.
_ne: NonExhaustive
Trait Implementations§
source§impl Clone for AttachmentReference
impl Clone for AttachmentReference
source§fn clone(&self) -> AttachmentReference
fn clone(&self) -> AttachmentReference
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more