From 38df943ffe21a82e0eadb11c5262deb0f5f88c0f Mon Sep 17 00:00:00 2001 From: Dzmitry Malyshau Date: Wed, 1 Dec 2021 22:22:14 -0500 Subject: [PATCH] Fix nightly warnings about docs --- wgpu-core/src/command/bundle.rs | 44 ++++++++++++++++----------------- wgpu-core/src/present.rs | 12 ++++----- 2 files changed, 28 insertions(+), 28 deletions(-) diff --git a/wgpu-core/src/command/bundle.rs b/wgpu-core/src/command/bundle.rs index f6825fb13..c27e4df5f 100644 --- a/wgpu-core/src/command/bundle.rs +++ b/wgpu-core/src/command/bundle.rs @@ -1,35 +1,35 @@ /*! Render Bundles - ## Software implementation +## Software implementation - The path from nothing to using a render bundle consists of 3 phases. +The path from nothing to using a render bundle consists of 3 phases. - ### Initial command encoding +### Initial command encoding - User creates a `RenderBundleEncoder` and populates it by issuing commands - from `bundle_ffi` module, just like with `RenderPass`, except that the - set of available commands is reduced. Everything is written into a `RawPass`. +User creates a `RenderBundleEncoder` and populates it by issuing commands +from `bundle_ffi` module, just like with `RenderPass`, except that the +set of available commands is reduced. Everything is written into a `RawPass`. - ### Bundle baking +### Bundle baking - Once the commands are encoded, user calls `render_bundle_encoder_finish`. - This is perhaps the most complex part of the logic. It consumes the - commands stored in `RawPass`, while validating everything, tracking the state, - and re-recording the commands into a separate `Vec`. It - doesn't actually execute any commands. +Once the commands are encoded, user calls `render_bundle_encoder_finish`. +This is perhaps the most complex part of the logic. It consumes the +commands stored in `RawPass`, while validating everything, tracking the state, +and re-recording the commands into a separate `Vec`. It +doesn't actually execute any commands. - What's more important, is that the produced vector of commands is "normalized", - which means it can be executed verbatim without any state tracking. More - formally, "normalized" command stream guarantees that any state required by - a draw call is set explicitly by one of the commands between the draw call - and the last changing of the pipeline. +What's more important, is that the produced vector of commands is "normalized", +which means it can be executed verbatim without any state tracking. More +formally, "normalized" command stream guarantees that any state required by +a draw call is set explicitly by one of the commands between the draw call +and the last changing of the pipeline. - ### Execution +### Execution - When the bundle is used in an actual render pass, `RenderBundle::execute` is - called. It goes through the commands and issues them into the native command - buffer. Thanks to the "normalized" property, it doesn't track any bind group - invalidations or index format changes. +When the bundle is used in an actual render pass, `RenderBundle::execute` is +called. It goes through the commands and issues them into the native command +buffer. Thanks to the "normalized" property, it doesn't track any bind group +invalidations or index format changes. !*/ #![allow(clippy::reversed_empty_ranges)] diff --git a/wgpu-core/src/present.rs b/wgpu-core/src/present.rs index 05e93f249..c1a8bd596 100644 --- a/wgpu-core/src/present.rs +++ b/wgpu-core/src/present.rs @@ -1,12 +1,12 @@ /*! Presentation. - ## Lifecycle +## Lifecycle - Whenever a submission detects the use of any surface texture, it adds it to the device - tracker for the duration of the submission (temporarily, while recording). - It's added with `UNINITIALIZED` state and transitioned into `empty()` state. - When this texture is presented, we remove it from the device tracker as well as - extract it from the hub. +Whenever a submission detects the use of any surface texture, it adds it to the device +tracker for the duration of the submission (temporarily, while recording). +It's added with `UNINITIALIZED` state and transitioned into `empty()` state. +When this texture is presented, we remove it from the device tracker as well as +extract it from the hub. !*/ #[cfg(feature = "trace")]