Struct vulkano::render_pass::Subpass
source · pub struct Subpass { /* private fields */ }
Expand description
Represents a subpass within a RenderPass
object.
This struct doesn’t correspond to anything in Vulkan. It is simply an equivalent to a
tuple of a render pass and subpass index. Contrary to a tuple, however, the existence of the
subpass is checked when the object is created. When you have a Subpass
you are guaranteed
that the given subpass does exist.
Implementations§
source§impl Subpass
impl Subpass
sourcepub fn from(render_pass: Arc<RenderPass>, id: u32) -> Option<Subpass>
pub fn from(render_pass: Arc<RenderPass>, id: u32) -> Option<Subpass>
Returns a handle that represents a subpass of a render pass.
sourcepub fn render_pass(&self) -> &Arc<RenderPass>
pub fn render_pass(&self) -> &Arc<RenderPass>
Returns the render pass of this subpass.
sourcepub fn subpass_desc(&self) -> &SubpassDescription
pub fn subpass_desc(&self) -> &SubpassDescription
Returns the subpass description for this subpass.
sourcepub fn is_last_subpass(&self) -> bool
pub fn is_last_subpass(&self) -> bool
Returns whether this subpass is the last one in the render pass. If true
is returned,
calling next_subpass
will panic.
sourcepub fn next_subpass(&mut self)
pub fn next_subpass(&mut self)
sourcepub fn num_color_attachments(&self) -> u32
pub fn num_color_attachments(&self) -> u32
Returns the number of color attachments in this subpass.
sourcepub fn num_samples(&self) -> Option<SampleCount>
pub fn num_samples(&self) -> Option<SampleCount>
Returns the number of samples in the color and/or depth/stencil attachments. Returns None
if there is no such attachment in this subpass.
sourcepub fn is_compatible_with(&self, shader_interface: &ShaderInterface) -> bool
pub fn is_compatible_with(&self, shader_interface: &ShaderInterface) -> bool
Returns true
if this subpass is compatible with the fragment output definition.