pub struct RenderPassDescriptor<'a> {
pub label: Label<'a>,
pub color_attachments: &'a [Option<RenderPassColorAttachment<'a>>],
pub depth_stencil_attachment: Option<RenderPassDepthStencilAttachment<'a>>,
pub timestamp_writes: Option<RenderPassTimestampWrites<'a>>,
pub occlusion_query_set: Option<&'a QuerySet>,
pub multiview_mask: Option<NonZeroU32>,
}Expand description
Describes the attachments of a render pass.
For use with CommandEncoder::begin_render_pass.
Corresponds to WebGPU GPURenderPassDescriptor.
Fields§
§label: Label<'a>Debug label of the render pass. This will show up in graphics debuggers for easy identification.
color_attachments: &'a [Option<RenderPassColorAttachment<'a>>]The color attachments of the render pass.
depth_stencil_attachment: Option<RenderPassDepthStencilAttachment<'a>>The depth and stencil attachment of the render pass, if any.
timestamp_writes: Option<RenderPassTimestampWrites<'a>>Defines which timestamp values will be written for this pass, and where to write them to.
Requires Features::TIMESTAMP_QUERY to be enabled.
occlusion_query_set: Option<&'a QuerySet>Defines where the occlusion query results will be stored for this pass.
multiview_mask: Option<NonZeroU32>The mask of multiview image layers to use for this render pass. For example, if you wish
to render to the first 2 layers, you would use 3=0b11. If you wanted ro render to only the
2nd layer, you would use 2=0b10. If you aren’t using multiview this should be None.
Note that setting bits higher than the number of texture layers is a validation error.
This doesn’t influence load/store/clear/etc operations, as those are defined for attachments,
therefore affecting all attachments. Meaning, this affects only any shaders executed on the RenderPass.
Trait Implementations§
Source§impl<'a> Clone for RenderPassDescriptor<'a>
impl<'a> Clone for RenderPassDescriptor<'a>
Source§fn clone(&self) -> RenderPassDescriptor<'a>
fn clone(&self) -> RenderPassDescriptor<'a>
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl<'a> Debug for RenderPassDescriptor<'a>
impl<'a> Debug for RenderPassDescriptor<'a>
Source§impl<'a> Default for RenderPassDescriptor<'a>
impl<'a> Default for RenderPassDescriptor<'a>
Source§fn default() -> RenderPassDescriptor<'a>
fn default() -> RenderPassDescriptor<'a>
Auto Trait Implementations§
impl<'a> Freeze for RenderPassDescriptor<'a>
impl<'a> !RefUnwindSafe for RenderPassDescriptor<'a>
impl<'a> Send for RenderPassDescriptor<'a>
impl<'a> Sync for RenderPassDescriptor<'a>
impl<'a> Unpin for RenderPassDescriptor<'a>
impl<'a> !UnwindSafe for RenderPassDescriptor<'a>
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
clone_to_uninit)