pub struct RenderBundle {
pub(crate) state: ResourceState<RenderBundleState>,
base: BasePass<ArcRenderCommand, Infallible>,
pub(super) is_depth_read_only: bool,
pub(super) is_stencil_read_only: bool,
pub(crate) device: Arc<Device>,
pub(super) buffer_memory_init_actions: Vec<BufferInitTrackerAction>,
pub(super) texture_memory_init_actions: Vec<TextureInitTrackerAction>,
label: String,
pub(crate) tracking_data: TrackingData,
discard_hal_labels: bool,
}Expand description
cbindgen:ignore
Fields§
§state: ResourceState<RenderBundleState>§base: BasePass<ArcRenderCommand, Infallible>§is_depth_read_only: bool§is_stencil_read_only: bool§device: Arc<Device>§buffer_memory_init_actions: Vec<BufferInitTrackerAction>§texture_memory_init_actions: Vec<TextureInitTrackerAction>§label: StringThe label from the descriptor used to create the resource.
tracking_data: TrackingData§discard_hal_labels: boolImplementations§
Source§impl RenderBundle
impl RenderBundle
pub(crate) fn state(&self) -> Result<&RenderBundleState, InvalidResourceError>
pub(crate) fn check_is_valid(&self) -> Result<(), InvalidResourceError>
pub fn invalid( device: Arc<Device>, desc: &RenderBundleDescriptor<'_>, ) -> Arc<Self>
pub(crate) fn to_base_pass( &self, ) -> BasePass<RenderCommand<ArcReferences>, Infallible>
Available on crate feature
trace only.Sourcepub(super) unsafe fn execute(
&self,
raw: &mut dyn DynCommandEncoder,
indirect_draw_validation_resources: &mut DrawResources,
indirect_draw_validation_batcher: &mut DrawBatcher,
snatch_guard: &SnatchGuard<'_>,
) -> Result<(), ExecutionError>
pub(super) unsafe fn execute( &self, raw: &mut dyn DynCommandEncoder, indirect_draw_validation_resources: &mut DrawResources, indirect_draw_validation_batcher: &mut DrawBatcher, snatch_guard: &SnatchGuard<'_>, ) -> Result<(), ExecutionError>
Actually encode the contents into a native command buffer.
This is partially duplicating the logic of render_pass_end.
However the point of this function is to be lighter, since we already had
a chance to go through the commands in render_bundle_encoder_finish.
Note that the function isn’t expected to fail, generally. All the validation has already been done by this point. Execution can still fail if a resource was destroyed or indirect draw validation cannot allocate a buffer.
Trait Implementations§
Source§impl Debug for RenderBundle
impl Debug for RenderBundle
Source§impl Drop for RenderBundle
impl Drop for RenderBundle
Source§impl Labeled for RenderBundle
impl Labeled for RenderBundle
Source§fn label(&self) -> &str
fn label(&self) -> &str
Returns a string identifying this resource for logging and errors. Read more
fn error_ident(&self) -> ResourceErrorIdent
Source§impl ParentDevice for RenderBundle
impl ParentDevice for RenderBundle
Source§impl ResourceType for RenderBundle
impl ResourceType for RenderBundle
Source§impl Trackable for RenderBundle
impl Trackable for RenderBundle
fn tracker_index(&self) -> TrackerIndex
impl Send for RenderBundle
Available on
send_sync only.impl Sync for RenderBundle
Available on
send_sync only.Auto Trait Implementations§
impl Freeze for RenderBundle
impl !RefUnwindSafe for RenderBundle
impl Unpin for RenderBundle
impl UnsafeUnpin for RenderBundle
impl !UnwindSafe for RenderBundle
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more